Blob Blame History Raw
diff -up dhcp-4.0.0/client/dhclient.c.leak dhcp-4.0.0/client/dhclient.c
--- dhcp-4.0.0/client/dhclient.c.leak	2008-02-05 17:55:57.000000000 -1000
+++ dhcp-4.0.0/client/dhclient.c	2008-02-05 18:01:54.000000000 -1000
@@ -2948,6 +2948,7 @@ void rewrite_client_leases ()
 		}
 	}
 	fflush (leaseFile);
+	fclose (leaseFile);
 }
 
 void write_lease_option (struct option_cache *oc,
@@ -3030,6 +3031,7 @@ write_duid(struct data_string *duid)
 	if (fflush(leaseFile) != 0)
 		return ISC_R_IOERROR;
 
+	fclose(leaseFile);
 	return ISC_R_SUCCESS;
 }
 
@@ -3129,6 +3131,7 @@ write_client6_lease(struct client_state 
 		}
 	}
 
+	fclose(leaseFile);
 	return ISC_R_SUCCESS;
 }
 
@@ -3264,6 +3267,8 @@ int write_client_lease (client, lease, r
 			return 0;
 		}
 	}
+
+	fclose(leaseFile);
 	return errors ? 0 : 1;
 }