Only clear stratum shares mandatorily on stratum dropouts when the pool does not support resume.
Free sessionid in clean_work and remove redundant setting of strings to NULL since the whole work struct is zeroed.