make sure that active_tool->tool_info is non-NULL before dereferencing it.

2003-05-12  Michael Natterer  <mitch@gimp.org>

	* app/tools/tool_manager.c (tool_manager_tool_changed): make sure
	that active_tool->tool_info is non-NULL before dereferencing it.
	(Spotted by Ville Ptsi).
This commit is contained in:
Michael Natterer 2003-05-12 14:11:37 +00:00 committed by Michael Natterer
parent eb335e05a0
commit 305dc2ffd7
2 changed files with 8 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2003-05-12 Michael Natterer <mitch@gimp.org>
* app/tools/tool_manager.c (tool_manager_tool_changed): make sure
that active_tool->tool_info is non-NULL before dereferencing it.
(Spotted by Ville Pätsi).
2003-05-11 Sven Neumann <sven@gimp.org>
* tools/pdbgen/pdb/guides.pdb: added a missing break that broke

View File

@ -753,7 +753,8 @@ tool_manager_tool_changed (GimpContext *user_context,
}
/* disconnect the old tool's context */
if (tool_manager->active_tool &&
if (tool_manager->active_tool &&
tool_manager->active_tool->tool_info &&
tool_manager->active_tool->tool_info->use_context)
{
GimpToolInfo *old_tool_info;