mirror of
https://github.com/troglobit/finit.git
synced 2026-10-27 12:20:54 +00:00
Cleanup, drop now unused internal function svc_is_unique()
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
1 parent
5ff27c4fe2
commit
b53f2f4a60
2 files changed
-22
No files matched your search
@@ -617,27 +617,6 @@ int svc_enabled(svc_t *svc)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int svc_is_unique(svc_t *svc)
|
|
||||||
{
|
|
||||||
svc_t *s, *iter = NULL;
|
|
||||||
int unique = 1;
|
|
||||||
|
|
||||||
for (s = svc_iterator(&iter, 1); s; s = svc_iterator(&iter, 0)) {
|
|
||||||
if (svc->type == SVC_TYPE_FREE)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
if (s == svc)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
if (s->job == svc->job) {
|
|
||||||
unique = 0;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return unique;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* break up "job:id job:id job:id ..." into several "job:id" tokens */
|
/* break up "job:id job:id job:id ..." into several "job:id" tokens */
|
||||||
static char *tokstr(char *str, size_t len)
|
static char *tokstr(char *str, size_t len)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -220,7 +220,6 @@ void svc_prune_bootstrap (void);
|
|||||||
|
|
||||||
void svc_enable (svc_t *svc);
|
void svc_enable (svc_t *svc);
|
||||||
int svc_enabled (svc_t *svc);
|
int svc_enabled (svc_t *svc);
|
||||||
int svc_is_unique (svc_t *svc);
|
|
||||||
|
|
||||||
int svc_parse_jobstr (char *str, size_t len, int (*found)(svc_t *), int (not_found)(char *, char *));
|
int svc_parse_jobstr (char *str, size_t len, int (*found)(svc_t *), int (not_found)(char *, char *));
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user