+ for (e = environ; *e; e++) {
+ /* Search for the variable */
+ if (strlen(*e) < l+1)
+ continue;
+
+ if (strncmp(*e, name, l) != 0 || *e[l] != '=')
+ continue;
+
+ /* We simply free the record, sicne we know that we created it previously */
+ avahi_free(*e);
+ *e = avahi_strdup_printf("%s=%s", name, value);
+ return;
+ }
+
+ assert(0);
+}
+
+static void run_script(int new, int interface, int protocol, const char *address) {
+ char *p;
+ int ret;
+ char ia[16], pa[16];
+ char name[IFNAMSIZ+1];
+
+ assert(interface > 0);