Don't use == to test IO conditions

2001-06-18  Bradford Hovinen  <hovinen@ximian.com>

	* config-log.c (slave_data_cb): Don't use == to test IO conditions
This commit is contained in:
Bradford Hovinen 2001-06-18 16:45:31 +00:00 committed by Bradford Hovinen (Gdict maintainer)
parent c7af228de9
commit aa7315ed93
3 changed files with 21 additions and 3 deletions

View file

@ -1334,11 +1334,13 @@ slave_data_cb (GIOChannel *channel, GIOCondition condition,
g_return_val_if_fail (slave->config_log != NULL, FALSE);
g_return_val_if_fail (IS_CONFIG_LOG (slave->config_log), FALSE);
if (condition == G_IO_HUP || slave->buffer->closed) {
DEBUG_MSG ("Condition is %d", condition);
if (condition & G_IO_HUP || slave->buffer->closed) {
slave_destroy (slave);
return FALSE;
}
else if (condition == G_IO_IN) {
else if (condition & G_IO_IN) {
if (load_log_entry (slave->config_log, TRUE, slave->buffer,
NULL) != NULL)
slave_broadcast_data (slave, slave->config_log);