Skip to content

Conversation

@ghost
Copy link

@ghost ghost commented Mar 2, 2022

No description provided.

@ghost ghost requested a review from weyrick March 2, 2022 18:22
@ghost
Copy link
Author

ghost commented Mar 2, 2022

Basically, I performed 4 changes:

  • Pointed pcapPP conan to upstream (updated master)

Updates required by newer version of pcapplusplus:

  • LoggerPP changed to Logger
  • changed public contructor to use clone method
  • pcapPP LOG macros added prefix 'PCPP_'

pcap_if_t *currInterface = interfaceList;
while (currInterface != NULL) {
if (currInterface->name != pcapDevice->getName()) {
currInterface = currInterface->next;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so now that we have clone(), we want to remove this whole block and avoid calling libpcap functions directly. all we have to do now is set _pcapDevice (from block on 144) to pcapDevice->clone()

if (_pcapDevice == nullptr) {
throw PcapException(fmt::format("Couldn't find interface by provided name: \"{}\". Available interfaces: {}", TARGET, ifNameList));
}
// end upstream PcapPlusPlus incompatibility block
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@weyrick this is right now?

@ghost ghost requested a review from weyrick March 3, 2022 21:33
@ghost ghost merged commit 5b630c6 into develop Mar 4, 2022
@ghost ghost deleted the feature/update-pcapplusplus-version branch March 4, 2022 15:32
@ghost ghost linked an issue Mar 5, 2022 that may be closed by this pull request
@ghost ghost self-assigned this Mar 5, 2022
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

update to latest pcapplusplus

1 participant