diff options
Diffstat (limited to 'gconf/gconf-preproc.c')
-rw-r--r-- | gconf/gconf-preproc.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/gconf/gconf-preproc.c b/gconf/gconf-preproc.c index af26d1a..eb50474 100644 --- a/gconf/gconf-preproc.c +++ b/gconf/gconf-preproc.c @@ -258,7 +258,7 @@ pp_list_find (gl_list_t list, struct file_data *dptr) const void *p; gl_list_iterator_t itr = gl_list_iterator (list); - while (gl_list_iterator_next (&itr, &p, NULL)) + while (!dptr->found && gl_list_iterator_next (&itr, &p, NULL)) { const char *dir = p; size_t size = strlen (dir) + 1 + dptr->namelen + 1; @@ -270,8 +270,7 @@ pp_list_find (gl_list_t list, struct file_data *dptr) strcpy (dptr->buf, dir); strcat (dptr->buf, "/"); strcat (dptr->buf, dptr->name); - if (dptr->found = (access (dptr->buf, F_OK) == 0)) - break; + dptr->found = access (dptr->buf, F_OK) == 0; } gl_list_iterator_free (&itr); return dptr->found; |