1
1
openmpi/orte/mca
Ralph Castain 53967bd698 Fix a memory corruption problem deep inside the registry when subscriptions/triggers are processed. The create_value function will malloc space for the pointers to keyval objects, but doesn't actually allocate space for the objects themselves. When constructing the gpr_notify_data object, we forgot to OBJ_NEW the keyval objects. Since the create_value function didn't explicitly NULL those memory locations, it just so happened that there was a non-NULL address in them....which we dutifully dumped a keyval into.
This fix includes two parts: (a) we now initialize the keyval pointer locations to NULL after the malloc, and (b) we now OBJ_NEW the keyvals prior to storing info in them.

BTW, in case anyone reads this and wonders why we don't just OBJ_NEW the keyvals in create_value, the reason is simply that some places in the code use static keyvals and simply assign those addresses into the value object's array. So not everyone wants to OBJ_NEW keyvals - by not forcing it here in create_value, we give the user the flexibility to do whatever they want.

This commit was SVN r13300.
2007-01-25 12:54:02 +00:00
..
errmgr Remove unneeded PARAM_INIT_FILE variable in configure.params files used by 2007-01-08 03:44:22 +00:00
gpr Fix a memory corruption problem deep inside the registry when subscriptions/triggers are processed. The create_value function will malloc space for the pointers to keyval objects, but doesn't actually allocate space for the objects themselves. When constructing the gpr_notify_data object, we forgot to OBJ_NEW the keyval objects. Since the create_value function didn't explicitly NULL those memory locations, it just so happened that there was a non-NULL address in them....which we dutifully dumped a keyval into. 2007-01-25 12:54:02 +00:00
iof Remove unneeded PARAM_INIT_FILE variable in configure.params files used by 2007-01-08 03:44:22 +00:00
ns Check for NULL before release, just to be safe 2007-01-17 21:29:34 +00:00
odls Clean up a compiler warning under bproc 2007-01-18 20:07:06 +00:00
oob Correctly close the sockets on a generic way. 2007-01-23 03:17:23 +00:00
pls When the user give a prefix that really means something. I expect to 2007-01-25 07:35:25 +00:00
ras Fixes trac:801 2007-01-24 14:45:42 +00:00
rds Remove this extra #if -- it wasn't necessary and was causing compiler warnings. 2007-01-17 13:53:02 +00:00
rmaps Store the mapping mode so that it can be recovered later 2007-01-18 20:00:15 +00:00
rmgr Update the Cray XT3 run-time support files to compile with latest RTE changes 2007-01-17 22:47:27 +00:00
rml Remove unneeded PARAM_INIT_FILE variable in configure.params files used by 2007-01-08 03:44:22 +00:00
schema Store the mapping mode so that it can be recovered later 2007-01-18 20:00:15 +00:00
sds Remove unneeded PARAM_INIT_FILE variable in configure.params files used by 2007-01-08 03:44:22 +00:00
smr Remove unneeded PARAM_INIT_FILE variable in configure.params files used by 2007-01-08 03:44:22 +00:00