const gchar *cmd_name;
gint r;
+ cmd_name = (session->cmd == FUZZY_WRITE ? "add" : "delete");
if (what == EV_WRITE) {
/* Send command to storage */
cmd.blocksize = session->h->block_size;
}
}
else if (what == EV_READ) {
- cmd_name = (session->cmd == FUZZY_WRITE ? "add" : "delete");
if (read (fd, buf, sizeof (buf)) == -1) {
msg_info ("cannot %s fuzzy hash for message <%s>, list %s:%d", cmd_name,
session->task->message_id, session->rule->symbol, session->flag);
}
else {
errno = ETIMEDOUT;
+ if (*(session->err) == NULL) {
+ g_set_error (session->err,
+ g_quark_from_static_string ("fuzzy check"), EINVAL, "%s fuzzy, IO timeout", cmd_name);
+ }
goto err;
}