rc_wait_service -> rc_service_wait

This commit is contained in:
Roy Marples 2007-09-29 17:03:38 +00:00
parent f795cd20f8
commit 7d5c82cf63
4 changed files with 8 additions and 8 deletions

View File

@ -615,7 +615,7 @@ void rc_schedule_clear (const char *service)
}
librc_hidden_def(rc_schedule_clear)
bool rc_wait_service (const char *service)
bool rc_service_wait (const char *service)
{
char *svc;
char *base;
@ -658,7 +658,7 @@ bool rc_wait_service (const char *service)
free (fifo);
return (retval);
}
librc_hidden_def(rc_wait_service)
librc_hidden_def(rc_service_wait)
char **rc_services_in_runlevel (const char *runlevel)
{

View File

@ -93,6 +93,7 @@ librc_hidden_proto(rc_service_mark)
librc_hidden_proto(rc_service_resolve)
librc_hidden_proto(rc_service_start)
librc_hidden_proto(rc_service_stop)
librc_hidden_proto(rc_service_wait)
librc_hidden_proto(rc_services_in_runlevel)
librc_hidden_proto(rc_services_in_state)
librc_hidden_proto(rc_services_scheduled)
@ -112,7 +113,6 @@ librc_hidden_proto(rc_strlist_delete)
librc_hidden_proto(rc_strlist_free)
librc_hidden_proto(rc_strlist_join)
librc_hidden_proto(rc_strlist_reverse)
librc_hidden_proto(rc_wait_service)
librc_hidden_proto(rc_waitpid)
librc_hidden_proto(rc_xmalloc)
librc_hidden_proto(rc_xrealloc)

View File

@ -129,7 +129,7 @@ void rc_schedule_clear (const char *service);
/*! Wait for a service to finish
* @param service to wait for
* @return true if service finished before timeout, otherwise false */
bool rc_wait_service (const char *service);
bool rc_service_wait (const char *service);
/*! Return a saved value for a service
* @param service to check

View File

@ -650,7 +650,7 @@ static void svc_start (bool deps)
continue;
}
if (! rc_wait_service (svc))
if (! rc_service_wait (svc))
eerror ("%s: timed out waiting for %s", applet, svc);
if ((svcs = rc_service_state (svc)) & RC_SERVICE_STARTED)
continue;
@ -842,7 +842,7 @@ static void svc_stop (bool deps)
if (svcs & RC_SERVICE_STARTED ||
svcs & RC_SERVICE_INACTIVE)
{
rc_wait_service (svc);
rc_service_wait (svc);
svcs = rc_service_state (svc);
if (svcs & RC_SERVICE_STARTED ||
svcs & RC_SERVICE_INACTIVE)
@ -862,7 +862,7 @@ static void svc_stop (bool deps)
continue;
/* We used to loop 3 times here - maybe re-do this if needed */
rc_wait_service (svc);
rc_service_wait (svc);
if (! (rc_service_state (svc) & RC_SERVICE_STOPPED)) {
if (rc_runlevel_stopping ()) {
/* If shutting down, we should stop even if a dependant failed */
@ -890,7 +890,7 @@ static void svc_stop (bool deps)
STRLIST_FOREACH (services, svc, i) {
if (rc_service_state (svc) & RC_SERVICE_STOPPED)
continue;
rc_wait_service (svc);
rc_service_wait (svc);
}
rc_strlist_free (services);