Use the global buffer

This commit is contained in:
Arun Prakash Jana 2017-07-03 18:09:11 +05:30
parent be8e9d5213
commit 76d600b072
No known key found for this signature in database
GPG key ID: A75979F35C080412

2
nnn.c
View file

@ -372,7 +372,7 @@ xmemrchr(const void *s, uchar ch, size_t n)
static char *
xdirname(const char *path)
{
static char buf[PATH_MAX];
static char *buf = g_buf;
static char *last_slash;
xstrlcpy(buf, path, PATH_MAX);