aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pcap-rpcap.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/pcap-rpcap.c b/pcap-rpcap.c
index 2e21ba0f..64b66c99 100644
--- a/pcap-rpcap.c
+++ b/pcap-rpcap.c
@@ -2566,8 +2566,9 @@ pcap_findalldevs_ex_remote(const char *source, struct pcap_rmtauth *auth, pcap_i
tmpstring[findalldevs_if.namelen] = 0;
/* Create the new device identifier */
- if (pcap_createsrcstr(tmpstring2, PCAP_SRC_IFREMOTE, host, port, tmpstring, errbuf) == -1)
- return -1;
+ if (pcap_createsrcstr(tmpstring2, PCAP_SRC_IFREMOTE,
+ host, port, tmpstring, errbuf) == -1)
+ goto error;
stringlen = strlen(tmpstring2);