some fixes for the other package lists
[openwrt.git] / openwrt / package / libpcap / patches / 102-alt-ether.patch
1 --- libpcap-0.8.3-orig/nametoaddr.c 2003-11-19 19:13:48.000000000 +0100
2 +++ libpcap-0.8.3-7/nametoaddr.c 2005-03-08 03:38:22.000000000 +0100
3 @@ -333,7 +333,7 @@
4 e = ep = (u_char *)malloc(6);
5
6 while (*s) {
7 - if (*s == ':')
8 + if (*s == ':' || *s == '.')
9 s += 1;
10 d = xdtoi(*s++);
11 if (isxdigit((unsigned char)*s)) {
12 --- libpcap-0.8.3-orig/scanner.l 2004-03-28 23:45:33.000000000 +0200
13 +++ libpcap-0.8.3-7/scanner.l 2005-03-08 03:38:22.000000000 +0100
14 @@ -80,6 +80,7 @@
15 N ([0-9]+|(0X|0x)[0-9A-Fa-f]+)
16 B ([0-9A-Fa-f][0-9A-Fa-f]?)
17 W ([0-9A-Fa-f][0-9A-Fa-f]?[0-9A-Fa-f]?[0-9A-Fa-f]?)
18 +X [0-9A-Fa-f]
19
20 %a 16000
21 %o 19000
22 @@ -296,7 +297,7 @@
23 {N} { yylval.i = stoi((char *)yytext); return NUM; }
24 ({N}\.{N})|({N}\.{N}\.{N})|({N}\.{N}\.{N}\.{N}) {
25 yylval.s = sdup((char *)yytext); return HID; }
26 -{B}:{B}:{B}:{B}:{B}:{B} { yylval.e = pcap_ether_aton((char *)yytext);
27 +({B}:{B}:{B}:{B}:{B}:{B})|({B}\.{B}\.{B}\.{B}\.{B}\.{B}) { yylval.e = pcap_ether_aton((char *)yytext);
28 return EID; }
29 {V6} {
30 #ifdef INET6
31 @@ -314,6 +315,8 @@
32 #endif /*INET6*/
33 }
34 {B}:+({B}:+)+ { bpf_error("bogus ethernet address %s", yytext); }
35 +{X}{12} { yylval.e = pcap_ether_aton((char *)yytext); return EID;}
36 +
37 icmptype { yylval.i = 0; return NUM; }
38 icmpcode { yylval.i = 1; return NUM; }
39 icmp-echoreply { yylval.i = 0; return NUM; }
This page took 0.042585 seconds and 5 git commands to generate.