Fix issue for the session name where it's not finding any task with a proper state first.  This should now operate properly.

git-svn-id: https://svn.code.sf.net/p/freeghost/code/trunk@2336 71f96598-fa45-0410-b640-bcd6f8691b32
Merge svn with master