SIPdump uses a deprecated PCAP function
Open
Nobody has claimed this yet.
maintenance/cleanup
portability
- Dominant language
- C
- Stars
- 13.6k
- Forks
- 2.6k
- PR merge metrics
- No merged PRs in 30d
Description
Seen when using latest'n'greatest macOS SDK
SIPdump.c:228:10: warning: 'pcap_lookupdev' is deprecated: use 'pcap_findalldevs' and use the first device
[-Wdeprecated-declarations]
dev = pcap_lookupdev(errbuf);
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/pcap/pcap.h:332:1: note:
'pcap_lookupdev' has been explicitly marked deprecated here
PCAP_DEPRECATED(pcap_lookupdev, "use 'pcap_findalldevs' and use the first device");
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/pcap/funcattrs.h:227:53: note:
expanded from macro 'PCAP_DEPRECATED'
#define PCAP_DEPRECATED(func, msg) __attribute__((deprecated(msg)))
^
1 warning generated.
I haven't seen that warning before but the pcap stuff doesn't seem new at all.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Inspect SIPdump.c around line 228 and compare the current pcap_lookupdev call with the macOS SDK warning. Check the pcap_findalldevs guidance in the installed pcap headers, then build SIPdump on macOS. Done means the device lookup uses the recommended API and the deprecation warning is gone.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, macos
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100