Set marks to NULL after freeing
Set marks to NULL after freeing

realloc() was being called on an already freed pointer.

Fixes #2900

Airblader/i3-original,Airblader/i3,stapelberg/i3,i3/i3,i3/i3,Airblader/i3,stapelberg/i3,Airblader/i3,i3/i3,Airblader/i3-original,Airblader/i3,i3/i3,stapelberg/i3,Airblader/i3-original,Airblader/i3-original,Airblader/i3-original,stapelberg/i3