Fixed problem with auto indices

SVN revision: 2216
This commit is contained in:
Stefan Ritt 2009-06-25 08:07:03 +00:00
parent 2ade7175ba
commit cb49a54ee6

View File

@ -8729,11 +8729,8 @@ void get_auto_index(LOGBOOK * lbs, int index, char *format, char *retstr, int si
el_retrieve(lbs, message_id, NULL, attr_list, attrib, lbs->n_attr, NULL, 0, NULL, NULL, att, NULL, el_retrieve(lbs, message_id, NULL, attr_list, attrib, lbs->n_attr, NULL, 0, NULL, NULL, att, NULL,
NULL); NULL);
/* if date part changed, start over with index */ /* if same date found, obtain largest index */
if (strlen(attrib[index]) > 0 && strncmp(attrib[index], retstr, loc) != 0) if (strlen(attrib[index]) > 0 && strncmp(attrib[index], retstr, loc) == 0)
old_index = 0;
else
/* retrieve old index */
if (atoi(attrib[index] + loc) > old_index) if (atoi(attrib[index] + loc) > old_index)
old_index = atoi(attrib[index] + loc); old_index = atoi(attrib[index] + loc);