about summary refs log tree commit diff stats
path: root/examples/parse_eapol
diff options
context:
space:
mode:
authorMarc <foxtrot@malloc.me>2023-01-15 20:22:15 +1100
committerMarc <foxtrot@malloc.me>2023-01-15 20:22:18 +1100
commit19fe0c6fa303bfedc57bf2d83f00e672c3dade47 (patch)
treed139d18962f6d2b51d63a846097f241fa8bc21d5 /examples/parse_eapol
parentacdad92339e601d47b9432fcdf43855b0e328fdd (diff)
downloadlibwifi-19fe0c6fa303bfedc57bf2d83f00e672c3dade47.tar.gz
libwifi-19fe0c6fa303bfedc57bf2d83f00e672c3dade47.tar.bz2
libwifi-19fe0c6fa303bfedc57bf2d83f00e672c3dade47.zip
examples/util: Fix example compilation on 32-bit hosts
Fixes #10
Diffstat (limited to 'examples/parse_eapol')
-rw-r--r--examples/parse_eapol/parse_eapol.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/parse_eapol/parse_eapol.c b/examples/parse_eapol/parse_eapol.c index e8f2827..fb42437 100644 --- a/examples/parse_eapol/parse_eapol.c +++ b/examples/parse_eapol/parse_eapol.c
@@ -5,6 +5,7 @@
5#include <stdio.h> 5#include <stdio.h>
6#include <stdlib.h> 6#include <stdlib.h>
7#include <string.h> 7#include <string.h>
8#include <inttypes.h>
8 9
9static int has_radiotap = 0; 10static int has_radiotap = 0;
10 11
@@ -38,7 +39,7 @@ void handle_pkt(unsigned char *args, const struct pcap_pkthdr *header, const uns
38 printf("EAPOL: Descriptor: %d\n", data.descriptor); 39 printf("EAPOL: Descriptor: %d\n", data.descriptor);
39 printf("EAPOL: Key Info: Information: 0x%04x\n", data.key_info.information); 40 printf("EAPOL: Key Info: Information: 0x%04x\n", data.key_info.information);
40 printf("EAPOL: Key Info: Key Length: %d\n", data.key_info.key_length); 41 printf("EAPOL: Key Info: Key Length: %d\n", data.key_info.key_length);
41 printf("EAPOL: Key Info: Replay Counter: %llu\n", data.key_info.replay_counter); 42 printf("EAPOL: Key Info: Replay Counter: %" PRIu64 "\n", data.key_info.replay_counter);
42 printf("EAPOL: Key Info: Nonce: "); 43 printf("EAPOL: Key Info: Nonce: ");
43 for (size_t i = 0; i < sizeof(data.key_info.nonce); ++i) { 44 for (size_t i = 0; i < sizeof(data.key_info.nonce); ++i) {
44 printf("%02x ", data.key_info.nonce[i]); 45 printf("%02x ", data.key_info.nonce[i]);