Commit 89cbe915 authored by Chad MILLER's avatar Chad MILLER

Merge from 5.0-bugteam local.

parents eb88db24 747c3c2b
...@@ -354,7 +354,7 @@ size_t unpack_dirname(char * to, const char *from) ...@@ -354,7 +354,7 @@ size_t unpack_dirname(char * to, const char *from)
length-= (size_t) (suffix-buff)-1; length-= (size_t) (suffix-buff)-1;
if (length+(h_length= strlen(tilde_expansion)) <= FN_REFLEN) if (length+(h_length= strlen(tilde_expansion)) <= FN_REFLEN)
{ {
if (tilde_expansion[h_length-1] == FN_LIBCHAR) if ((h_length > 0) && (tilde_expansion[h_length-1] == FN_LIBCHAR))
h_length--; h_length--;
if (buff+h_length < suffix) if (buff+h_length < suffix)
bmove(buff+h_length,suffix,length); bmove(buff+h_length,suffix,length);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment