Lines Matching full:notify
826 target_next_notify(struct target_notify *notify) in target_next_notify() argument
828 if (notify == NULL) in target_next_notify()
831 return (SLIST_NEXT(notify, tn)); in target_next_notify()
838 struct target_notify *notify, *temp, *prev; in target_new_notify() local
840 SLIST_FOREACH(notify, &target_notifylist, tn) in target_new_notify()
841 if (strcmp(nname, notify->name) == 0) in target_new_notify()
844 if ((notify = (struct target_notify *)malloc(sizeof(*notify))) == NULL) in target_new_notify()
847 memset(notify, 0, sizeof(*notify)); in target_new_notify()
848 strlcpy(notify->name, nname, sizeof(notify->name)); in target_new_notify()
852 SLIST_INSERT_HEAD(&target_notifylist, notify, tn); in target_new_notify()
853 return (notify); in target_new_notify()
863 SLIST_INSERT_AFTER(prev, notify, tn); in target_new_notify()
865 SLIST_INSERT_AFTER(temp, notify, tn); in target_new_notify()
867 syslog(LOG_ERR, "Notification target %s exists", notify->name); in target_new_notify()
868 free(notify); in target_new_notify()
872 return (notify); in target_new_notify()
876 target_delete_notify(struct target_notify *notify) in target_delete_notify() argument
878 SLIST_REMOVE(&target_notifylist, notify, target_notify, tn); in target_delete_notify()
879 free(notify); in target_delete_notify()
889 struct target_notify *notify; in target_flush_all() local
905 while ((notify = SLIST_FIRST(&target_notifylist)) != NULL) { in target_flush_all()
907 free(notify); in target_flush_all()