Fix problem with socket path length when using SHA256.
Mistake in comparing hash type.
Merge pull request #11705 from cachedout/11486

Fix problem with socket path length when using SHA256.