From: Nathan S. Evans Date: Wed, 10 Nov 2010 12:37:44 +0000 (+0000) Subject: codesonar fix X-Git-Tag: initial-import-from-subversion-38251~19774 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=f2d0582c044e1c7ea338db930fe002d2f41841b0;p=oweals%2Fgnunet.git codesonar fix --- diff --git a/src/transport/plugin_transport_udp.c b/src/transport/plugin_transport_udp.c index 3b669d80c..d95147a1a 100644 --- a/src/transport/plugin_transport_udp.c +++ b/src/transport/plugin_transport_udp.c @@ -723,12 +723,15 @@ run_gnunet_nat_client (struct Plugin *plugin, const char *addr, size_t addrlen) #endif /* Start the server process */ - proc = GNUNET_OS_start_process(NULL, NULL, "gnunet-nat-client", "gnunet-nat-client", plugin->external_address, address_as_string, port_as_string, NULL); + proc = GNUNET_OS_start_process (NULL, NULL, "gnunet-nat-client", "gnunet-nat-client", plugin->external_address, address_as_string, port_as_string, NULL); GNUNET_free(address_as_string); GNUNET_free(port_as_string); - GNUNET_OS_process_wait (proc); - GNUNET_OS_process_close (proc); - proc = NULL; + if (proc != NULL) + { + GNUNET_OS_process_wait (proc); + GNUNET_OS_process_close (proc); + proc = NULL; + } } /**