Skip to content

Aggiunto pbridge.c - Lai Jennifer#388

Open
jenniferlai5 wants to merge 1 commit intolucaderi:masterfrom
jenniferlai5:master
Open

Aggiunto pbridge.c - Lai Jennifer#388
jenniferlai5 wants to merge 1 commit intolucaderi:masterfrom
jenniferlai5:master

Conversation

@jenniferlai5
Copy link
Copy Markdown

No description provided.

Copy link
Copy Markdown
Owner

@lucaderi lucaderi left a comment

Choose a reason for hiding this comment

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

Ci sono delle buone idee ma occorre semplificare il codice.


pthread_t t_ab, t_ba;

if(pthread_create(&t_ab, NULL, capture_loop, &ctx_ab) != 0){
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Come detto ieri i thread si possono evitare in quanto non necessari


printf("Forwarding to %s \n", out_device);
promisc = 1;
if((pd_out_b = pcap_open_live(out_device, snaplen, promisc, 500, errbuf)) == NULL){
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Qui hai creato troppe interfacce. Se proprio vuoi interfacce per direzione dovresti aggiungere una cos del tipo pcap_set_direction in modo da non catturare nel verso sbagliato

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.

2 participants