- Fix derefercing of null pointer
[reactos.git] / reactos / base / services / dhcp / dhclient.c
index 28557e8..eee8e26 100644 (file)
@@ -581,8 +581,10 @@ bind_lease(struct interface_info *ip)
     Adapter = AdapterFindInfo( ip );
 
     if( Adapter )  setup_adapter( Adapter, new_lease );
     Adapter = AdapterFindInfo( ip );
 
     if( Adapter )  setup_adapter( Adapter, new_lease );
-    else warning("Could not find adapter for info %p\n", ip);
-
+    else {
+        warning("Could not find adapter for info %p\n", ip);
+        return;
+    }
     set_name_servers( Adapter, new_lease );
 }
 
     set_name_servers( Adapter, new_lease );
 }