Rework SSHS helper error conditions and returns.
Properly check for them where needed.
Use strdup() to get a duplicate of a standard string.