Lines Matching defs:entry
68 * This structure is used to hold a SNMP table entry
89 * Create entry into the printer table.
94 struct printer_entry *entry = NULL;
100 if ((entry = malloc(sizeof(*entry))) == NULL) {
104 memset(entry, 0, sizeof(*entry));
105 entry->index = devEntry->index;
106 INSERT_OBJECT_INT(entry, &printer_tbl);
107 return (entry);
111 * Delete entry from the printer table.
114 printer_entry_delete(struct printer_entry *entry)
117 assert(entry != NULL);
118 if (entry == NULL)
121 TAILQ_REMOVE(&printer_tbl, entry, link);
122 free(entry);
131 struct printer_entry *entry;
133 TAILQ_FOREACH(entry, &printer_tbl, link)
134 if (entry->index == idx)
135 return (entry);
279 "hrPrinterTable: printcap entry for %s "
320 struct printer_entry *entry;
328 /* mark each entry as missing */
329 TAILQ_FOREACH(entry, &printer_tbl, link)
330 entry->flags &= ~HR_PRINTER_FOUND;
337 entry = TAILQ_FIRST(&printer_tbl);
338 while (entry != NULL) {
339 entry_tmp = TAILQ_NEXT(entry, link);
340 if (!(entry->flags & HR_PRINTER_FOUND))
341 printer_entry_delete(entry);
342 entry = entry_tmp;
354 struct printer_entry *entry;
361 if ((entry = NEXT_OBJECT_INT(&printer_tbl, &value->var,
365 value->var.subs[sub] = entry->index;
369 if ((entry = FIND_OBJECT_INT(&printer_tbl, &value->var,
375 if ((entry = FIND_OBJECT_INT(&printer_tbl, &value->var,
390 value->v.integer = entry->status;
394 return (string_get(value, entry->detectedErrorState,
395 sizeof(entry->detectedErrorState)));