- Fix - allocate space for the '\0' character for tvheadend_webroot

(cherry picked from commit 3b38a9e012)
This commit is contained in:
Benny Morgan 2013-06-30 22:13:20 +02:00 committed by Adam Sutton
parent 4c61110d68
commit 6fb9a8f034

View file

@ -556,7 +556,7 @@ main(int argc, char **argv)
if (*tvheadend_webroot == '/')
tmp = strdup(tvheadend_webroot);
else {
tmp = malloc(strlen(tvheadend_webroot)+1);
tmp = malloc(strlen(tvheadend_webroot)+2);
*tmp = '/';
strcpy(tmp+1, tvheadend_webroot);
}