XMLCtx->job_conditions[XMLCtx->row][XMLCtx->position].attr_id.state = edg_wll_StringToStat(attr[1]);
}
if ( (i+1) == EDG_WLL_QUERY_ATTR_JDL_ATTR) {
- if (!attr[0] || !attr[1]) { unexp() break;}
- if (strcmp(attr[0],"name")) { unexp() break;}
- XMLCtx->job_conditions[XMLCtx->row][XMLCtx->position].attr_id.tag = strdup(attr[1]);
+ if (!attr[0] || !attr[1])
+ XMLCtx->job_conditions[XMLCtx->row][XMLCtx->position].attr_id.tag = NULL;
+ else if (strcmp(attr[0],"name")) { unexp() break;}
+ else XMLCtx->job_conditions[XMLCtx->row][XMLCtx->position].attr_id.tag = strdup(attr[1]);
}
XMLCtx->job_conditions[XMLCtx->row][XMLCtx->position].attr = i+1;
}
char *cols = NULL,*aux;
for (i=0; conds && conds[i]; i++) {
- for (j=0; notif_cols[j].qrec.attr && notif_cols[j].qrec.attr != conds[i]->attr; j++);
+ for (j=0; notif_cols[j].qrec.attr &&
+ (notif_cols[j].qrec.attr != conds[i]->attr ||
+ (notif_cols[j].qrec.attr == EDG_WLL_QUERY_ATTR_JDL_ATTR &&
+ (!conds[i]->attr_id.tag || strcmp(notif_cols[j].qrec.attr_id.tag,conds[i]->attr_id.tag))
+ )
+ ); j++);
if (notif_cols[j].qrec.attr) {
if (conds[i][1].attr && conds[i][0].op != EDG_WLL_QUERY_OP_EQUAL) {
char buf[1000];
}
break;
case EDG_WLL_QUERY_ATTR_JDL_ATTR:
-
- if (stat->jdl != NULL) {
+ if (conds[i][j].op == EDG_WLL_QUERY_OP_CHANGED &&
+ conds[i][j].attr_id.tag == NULL &&
+ oldstat &&
+ (oldstat->jdl == NULL ||
+ (stat->jdl && strcmp(oldstat->jdl,stat->jdl))
+ )
+ ) goto or_satisfied;
+
+ if (stat->jdl != NULL && conds[i][j].attr_id.tag) {
struct cclassad *ad = NULL;
char *extr_val = NULL;