aboutsummaryrefslogtreecommitdiffstats
path: root/src/configuration.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/configuration.h')
-rw-r--r--src/configuration.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/configuration.h b/src/configuration.h
index 7eb548c..ceb0aad 100644
--- a/src/configuration.h
+++ b/src/configuration.h
@@ -33,7 +33,7 @@ typedef struct {
slapt_source_t **src;
uint32_t count;
} slapt_source_list_t;
-#define slapt_source_list_t_foreach(item, list) slapt_source_t *item; for (uint32_t item##_counter = 0; item = list->src[item##_counter], item##_counter < list->count; item##_counter++)
+#define slapt_source_list_t_foreach(item, list) slapt_source_t *item; for (uint32_t item##_counter = 0; (item##_counter < list->count) && (item = list->src[item##_counter]); item##_counter++)
typedef struct {
char working_dir[SLAPT_WORKINGDIR_TOKEN_LEN];