change the order of the ||'ed items in the if to avoid using an

2006-01-23  Elijah Newren  <newren gmail com>

	* src/display.c (meta_display_check_threshold_reached): change the
	order of the ||'ed items in the if to avoid using an uninitialized
	value

	* src/prefs.c (meta_prefs_init): fix a couple uninitialized value
	problems
This commit is contained in:
Elijah Newren 2006-01-24 01:07:41 +00:00 committed by Elijah Newren
parent 9abec54da6
commit 405e21a82a
3 changed files with 18 additions and 6 deletions

View File

@ -1,3 +1,12 @@
2006-01-23 Elijah Newren <newren gmail com>
* src/display.c (meta_display_check_threshold_reached): change the
order of the ||'ed items in the if to avoid using an uninitialized
value
* src/prefs.c (meta_prefs_init): fix a couple uninitialized value
problems
2006-01-21 Elijah Newren <newren gmail com>
Patch from Christian Kirbach to prevent a critical warning crasher

View File

@ -3616,8 +3616,8 @@ meta_display_check_threshold_reached (MetaDisplay *display,
int y)
{
/* Don't bother doing the check again if we've already reached the threshold */
if (display->grab_threshold_movement_reached ||
meta_prefs_get_raise_on_click ())
if (meta_prefs_get_raise_on_click () ||
display->grab_threshold_movement_reached)
return;
if (ABS (display->grab_initial_x - x) >= 8 ||

View File

@ -434,11 +434,14 @@ meta_prefs_init (void)
cleanup_error (&err);
update_button_layout (str_val);
g_free (str_val);
if (get_bool (KEY_VISUAL_BELL, &bool_val) ||
get_bool (KEY_AUDIBLE_BELL, &bool_val_2))
update_visual_bell (bool_val, bool_val_2);
bool_val = provide_visual_bell;
bool_val_2 = bell_is_audible;
gboolean update_visual = get_bool (KEY_VISUAL_BELL, &bool_val);
gboolean update_audible = get_bool (KEY_AUDIBLE_BELL, &bool_val_2);
if (update_visual || update_audible)
update_visual_bell (bool_val, bool_val_2);
str_val = gconf_client_get_string (default_client, KEY_VISUAL_BELL_TYPE,
&err);
cleanup_error (&err);