scrsnap: allocate memory for snapshots only when needed