Lines Matching defs:notify
825 target_next_notify(struct target_notify *notify)
827 if (notify == NULL)
830 return (SLIST_NEXT(notify, tn));
837 struct target_notify *notify, *temp, *prev;
839 SLIST_FOREACH(notify, &target_notifylist, tn)
840 if (strcmp(nname, notify->name) == 0)
843 if ((notify = (struct target_notify *)malloc(sizeof(*notify))) == NULL)
846 memset(notify, 0, sizeof(*notify));
847 strlcpy(notify->name, nname, sizeof(notify->name));
851 SLIST_INSERT_HEAD(&target_notifylist, notify, tn);
852 return (notify);
862 SLIST_INSERT_AFTER(prev, notify, tn);
864 SLIST_INSERT_AFTER(temp, notify, tn);
866 syslog(LOG_ERR, "Notification target %s exists", notify->name);
867 free(notify);
871 return (notify);
875 target_delete_notify(struct target_notify *notify)
877 SLIST_REMOVE(&target_notifylist, notify, target_notify, tn);
878 free(notify);
888 struct target_notify *notify;
904 while ((notify = SLIST_FIRST(&target_notifylist)) != NULL) {
906 free(notify);