Check asprintf return code

Signed-off-by: Morten Hustveit <mortehu@google.com>
Place new normal windows in next empty workspace

Prior to this commit, the current workspace was used.

Signed-off-by: Morten Hustveit <mortehu@google.com>