Show Navigation
Conversation
Notices
-
Anybody know C well enough to tell me what this does?
if (strcmp (row[slave_io_field], "Yes") != 0 || strcmp (row[slave_sql_field], "Yes") != 0) {
mysql_free_result (res);
mysql_close (&mysql);
die (STATE_CRITICAL, "%s\n", slaveresult);
}
It's clearly checking for "Yes", but if it finds "Yes!" what happens? I could change things to be the string I'm finding, but that's not really ideal.
-
@musicman if (row[slave_io_field] != "yes" or row[slave_sql_field] != "yes") then die with an error