diff options
author | Linus Nordberg <linus@nordu.net> | 2011-03-11 13:18:44 +0100 |
---|---|---|
committer | Linus Nordberg <linus@nordu.net> | 2011-03-11 13:18:44 +0100 |
commit | 73d7353cb7a244d08fdd8b6d14e01db4b00824b7 (patch) | |
tree | ad6f2387878e1304c4aa0e2cbac5eb52dca05d31 /lib/conf.c | |
parent | 6d5c276000a65e35dae2f672913c767e696cb56a (diff) |
Handle an ENOMEM case in conf.c.
Diffstat (limited to 'lib/conf.c')
-rw-r--r-- | lib/conf.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -89,6 +89,8 @@ rs_context_read_config(struct rs_context *ctx, const char *config_file) return rs_err_ctx_push_fl (ctx, RSE_CONFIG, __FILE__, __LINE__, "missing config name"); r->name = strdup (s); + if (!r->name) + return rs_err_ctx_push_fl (ctx, RSE_NOMEM, __FILE__, __LINE__, NULL); typestr = cfg_getstr (cfg_config, "type"); if (!strcmp (typestr, "UDP")) |