Fix segfault since we free the wrong address.
Happens because strsep() modifies the location pointed by its argument.