Commit 4bab7fb6 authored by Robert Sprowson's avatar Robert Sprowson
Browse files

Fix for potential NULL pointer dereference

Get the object_id after the check for menu_int being NULL, not before.
Found by cppcheck.

Version 0.23. Tagged as 'ColourMenu-0_23'
parent 46472567
/* (0.22)
/* (0.23)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 0.22
#define Module_MajorVersion_CMHG 0.23
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 18 Aug 2015
#define Module_Date_CMHG 09 Sep 2018
#define Module_MajorVersion "0.22"
#define Module_Version 22
#define Module_MajorVersion "0.23"
#define Module_Version 23
#define Module_MinorVersion ""
#define Module_Date "18 Aug 2015"
#define Module_Date "09 Sep 2018"
#define Module_ApplicationDate "18-Aug-15"
#define Module_ApplicationDate "09-Sep-18"
#define Module_ComponentName "ColourMenu"
#define Module_ComponentPath "castle/RiscOS/Sources/Toolbox/ColourMenu"
#define Module_FullVersion "0.22"
#define Module_HelpVersion "0.22 (18 Aug 2015)"
#define Module_LibraryVersionInfo "0:22"
#define Module_FullVersion "0.23"
#define Module_HelpVersion "0.23 (09 Sep 2018)"
#define Module_LibraryVersionInfo "0:23"
......@@ -165,7 +165,7 @@ _kernel_oserror *event_help_request (wimp_Message message_block, TaskDescriptor
_kernel_oserror *e;
ColourMenuInternal *menu_int = global_menu.current;
wimp_Message help_reply;
ObjectID object_id = menu_int->object_id;
ObjectID object_id;
int buffer[64];
if (!menu_int) return NULL;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment