]> The Tcpdump Group git mirrors - libpcap/commitdiff
haiku: squelch some unused-variable warnings.
authorGuy Harris <[email protected]>
Tue, 12 Jul 2022 20:29:40 +0000 (13:29 -0700)
committerGuy Harris <[email protected]>
Thu, 14 Jul 2022 05:19:59 +0000 (22:19 -0700)
In these cases, it's "unused by design" rather than "unused because we
haven't finished writing it".

(cherry picked from commit 143cdb512c67de0da3245014d9b6f6d67f2f1730)

pcap-haiku.cpp

index 4606ca0e252e5038b7956e1b193c17f0886c98f5..8ae9119c2ccf32203ef3e38877f0f8e39bc4f62b 100644 (file)
@@ -47,12 +47,11 @@ prepare_request(struct ifreq& request, const char* name)
 
 
 static int
-pcap_read_haiku(pcap_t* handle, int maxPackets, pcap_handler callback,
+pcap_read_haiku(pcap_t* handle, int maxPackets _U_, pcap_handler callback,
        u_char* userdata)
 {
        // Receive a single packet
 
-       struct pcap_haiku* handlep = (struct pcap_haiku*)handle->priv;
        u_char* buffer = (u_char*)handle->buffer + handle->offset;
        struct sockaddr_dl from;
        ssize_t bytesReceived;
@@ -269,7 +268,7 @@ pcap_create_interface(const char *device, char *errorBuffer)
 }
 
 static int
-can_be_bound(const char *name)
+can_be_bound(const char *name _U_)
 {
        return 1;
 }