mirror of
https://github.com/simon987/sist2.git
synced 2025-12-11 14:38:54 +00:00
Fix for #29
This commit is contained in:
@@ -259,8 +259,10 @@ char *abspath(const char *path) {
|
||||
if (abs == NULL) {
|
||||
return NULL;
|
||||
}
|
||||
abs = realloc(abs, strlen(abs) + 2);
|
||||
strcat(abs, "/");
|
||||
if (strlen(abs) > 1) {
|
||||
abs = realloc(abs, strlen(abs) + 2);
|
||||
strcat(abs, "/");
|
||||
}
|
||||
|
||||
wordfree(&w);
|
||||
return abs;
|
||||
|
||||
Reference in New Issue
Block a user