From: Jan 'Moskyt' Matejka Date: Mon, 13 May 2013 08:00:10 +0000 (+0200) Subject: Opt: strdup -> xstrdup X-Git-Tag: v5.99~25^2~50 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=de636dbe4e9fb2c1f4d29de203d9ff2528206afc;p=libucw.git Opt: strdup -> xstrdup --- diff --git a/ucw/opt.c b/ucw/opt.c index ed847993..d1a19f9b 100644 --- a/ucw/opt.c +++ b/ucw/opt.c @@ -264,7 +264,7 @@ static void opt_parse_value(struct opt_precomputed_option * opt, char * value, i if (!value) item->ptr = NULL; else - item->ptr = strdup(value); + item->ptr = xstrdup(value); break; default: ASSERT(0); @@ -574,7 +574,7 @@ static void add_tea(const char * name) { fprintf(stderr, "Cannot boil more than %d teas.\n", MAX_TEA_COUNT); exit(OPT_EXIT_BAD_ARGS); } - tea_list[tea_num++] = strdup(name); + tea_list[tea_num++] = xstrdup(name); } static void boil_tea(const char * name) {