]> asedeno.scripts.mit.edu Git - PuTTY.git/blobdiff - windows/winshare.c
Handle packets with no type byte by returning SSH_MSG_UNIMPLEMENTED.
[PuTTY.git] / windows / winshare.c
index a63325cb8abd24bd200797bfcc04061dac55e6d4..2f21638e76c6c01b914a576291c171b4c0768156 100644 (file)
@@ -157,6 +157,7 @@ int platform_ssh_share(const char *pi_name, Conf *conf,
         if (!make_private_security_descriptor(MUTEX_ALL_ACCESS,
                                               &psd, &acl, logtext)) {
             sfree(mutexname);
+            sfree(name);
             return SHARE_NONE;
         }
 
@@ -171,6 +172,7 @@ int platform_ssh_share(const char *pi_name, Conf *conf,
             *logtext = dupprintf("CreateMutex(\"%s\") failed: %s",
                                  mutexname, win_strerror(GetLastError()));
             sfree(mutexname);
+            sfree(name);
             LocalFree(psd);
             LocalFree(acl);
             return SHARE_NONE;