WorkspacesGroup passed into validateInputs causing segfaults

This was originally [trac #10438](http://trac.mantidproject.org/mantid/ticket/10438).

**To test:** Try running an algorithm (one in the original ticket description) with a WorkspaceGroup.