Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
freebsd
GitHub Repository: freebsd/freebsd-ports-kde
Path: blob/main/net-mgmt/chillispot/files/patch-src_chilli.c
16461 views
1
--- src/chilli.c.orig Mon Dec 26 08:06:46 2005
2
+++ src/chilli.c Mon Dec 26 08:10:01 2005
3
@@ -14,13 +14,14 @@
4
#include <stdio.h>
5
#include <string.h>
6
#include <stdlib.h>
7
+#include <sys/types.h>
8
+#include <sys/socket.h>
9
+#include <netinet/in.h>
10
#include <arpa/inet.h>
11
#include <sys/stat.h>
12
#include <unistd.h>
13
-#include <sys/socket.h>
14
#include <net/if.h>
15
#include <errno.h>
16
-#include <sys/types.h>
17
18
#if defined(__linux__)
19
#include <asm/types.h>
20
@@ -460,13 +461,13 @@
21
memset(options.uamokmask, 0, sizeof(options.uamokmask));
22
options.uamoknetlen = 0;
23
for (numargs = 0; numargs < args_info.uamallowed_given; ++numargs) {
24
+ char *p1 = NULL;
25
+ char *p2 = NULL;
26
+ char *p3 = malloc(strlen(args_info.uamallowed_arg[numargs])+1);
27
if (options.debug & DEBUG_CONF) {
28
printf ("Uamallowed #%d: %s\n",
29
numargs, args_info.uamallowed_arg[numargs]);
30
}
31
- char *p1 = NULL;
32
- char *p2 = NULL;
33
- char *p3 = malloc(strlen(args_info.uamallowed_arg[numargs])+1);
34
strcpy(p3, args_info.uamallowed_arg[numargs]);
35
p1 = p3;
36
if ((p2 = strchr(p1, ','))) {
37
@@ -766,14 +767,14 @@
38
memset(options.macok, 0, sizeof(options.macok));
39
options.macoklen = 0;
40
for (numargs = 0; numargs < args_info.macallowed_given; ++numargs) {
41
- if (options.debug & DEBUG_CONF) {
42
- printf ("Macallowed #%d: %s\n", numargs,
43
- args_info.macallowed_arg[numargs]);
44
- }
45
char *p1 = NULL;
46
char *p2 = NULL;
47
char *p3 = malloc(strlen(args_info.macallowed_arg[numargs])+1);
48
int i;
49
+ if (options.debug & DEBUG_CONF) {
50
+ printf ("Macallowed #%d: %s\n", numargs,
51
+ args_info.macallowed_arg[numargs]);
52
+ }
53
strcpy(p3, args_info.macallowed_arg[numargs]);
54
p1 = p3;
55
if ((p2 = strchr(p1, ','))) {
56
57