shut up GCC on -Wmaybe-initialized warnings

Admittedly, these are totally bogus, but a clean build is a happy build.

Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
Dave Reisner 2014-12-14 12:35:00 -05:00 committed by Allan McRae
parent 0cd174efd5
commit 16259d728e
2 changed files with 2 additions and 3 deletions

View File

@ -459,7 +459,7 @@ static int process_cleanmethods(alpm_list_t *values,
static void setrepeatingoption(char *ptr, const char *option,
alpm_list_t **list)
{
char *val, *saveptr;
char *val, *saveptr = NULL;
val = strtok_r(ptr, " ", &saveptr);
while(val) {

View File

@ -341,8 +341,7 @@ static void invalid_opt(int used, const char *opt1, const char *opt2)
static int parsearg_util_addlist(alpm_list_t **list)
{
char *i, *save;
char *i, *save = NULL;
for(i = strtok_r(optarg, ",", &save); i; i = strtok_r(NULL, ",", &save)) {
*list = alpm_list_add(*list, strdup(i));