mirror of
https://github.com/yarrick/iodine.git
synced 2024-12-22 13:23:32 +02:00
Initialize get_resolvconf_addr variable rv to NULL
Getting warning compiling for Android: ./util.c:35:6: warning: variable 'rv' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized] if (sscanf(buf, "%15s", addr) == 1) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./util.c:79:9: note: uninitialized use occurs here return rv; ^~
This commit is contained in:
parent
cfd0b07e1f
commit
f5a82afe29
1 changed files with 1 additions and 1 deletions
|
@ -22,7 +22,7 @@
|
|||
char *get_resolvconf_addr(void)
|
||||
{
|
||||
static char addr[16];
|
||||
char *rv;
|
||||
char *rv = NULL;
|
||||
#ifndef WINDOWS32
|
||||
char buf[80];
|
||||
FILE *fp;
|
||||
|
|
Loading…
Reference in a new issue