[ros-dev] [ros-diffs] [akhaldi] 65133: [LOGOFF] * Plug some leaks. CIDs 716284 and 716285. CORE-7975

Thomas Faber thomas.faber at reactos.org
Fri Oct 31 10:09:33 UTC 2014


Hey,

On 2014-10-31 10:22, akhaldi at svn.reactos.org wrote:
> @@ -90,6 +91,7 @@
>  			//Invalid parameter detected
>  			if (AllocAndLoadString(&lpIllegalMsg, GetModuleHandle(NULL), IDS_ILLEGAL_PARAM))
>  			_putts(lpIllegalMsg);
> +			LocalFree(lpIllegalMsg);
>  			return FALSE;
>  		}
>  	}
> 

This needs braces. Both puts and LocalFree should only be executed if
AllocAndLoadString succeeds (but return FALSE in either case).

Thanks!



More information about the Ros-dev mailing list