mirror of
https://github.com/jarun/nnn.git
synced 2024-12-01 02:49:44 +00:00
Declare var at top of block
This commit is contained in:
parent
d1ed0cff11
commit
7ceda4f7d2
8
noice.c
8
noice.c
|
@ -198,12 +198,12 @@ spawn(const char *file, const char *arg, const char *dir)
|
||||||
char *
|
char *
|
||||||
xgetenv(char *name, char *fallback)
|
xgetenv(char *name, char *fallback)
|
||||||
{
|
{
|
||||||
|
char *value;
|
||||||
|
|
||||||
if (name == NULL)
|
if (name == NULL)
|
||||||
return fallback;
|
return fallback;
|
||||||
char *value = getenv(name);
|
value = getenv(name);
|
||||||
if (value)
|
return value ? value : fallback;
|
||||||
return value;
|
|
||||||
return fallback;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
char *
|
char *
|
||||||
|
|
Loading…
Reference in a new issue