summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/wellenreiter/libwellenreiter/source/cardmode.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/noncore/net/wellenreiter/libwellenreiter/source/cardmode.cc b/noncore/net/wellenreiter/libwellenreiter/source/cardmode.cc
index cf50d8c..626b28c 100644
--- a/noncore/net/wellenreiter/libwellenreiter/source/cardmode.cc
+++ b/noncore/net/wellenreiter/libwellenreiter/source/cardmode.cc
@@ -57,13 +57,13 @@ int card_into_monitormode (pcap_t **orighandle, const char *device, int cardtype
57 { 57 {
58 int skfd; 58 int skfd;
59 skfd = socket(AF_INET, SOCK_STREAM, 0); 59 skfd = socket(AF_INET, SOCK_STREAM, 0);
60 struct iwreq wrq; 60 struct iwreq wrq;
61 wrq.u.mode = IW_MODE_MONITOR; 61 wrq.u.mode = IW_MODE_MONITOR;
62 62
63 if(iw_set_ext(skfd,device,SIOCSIWMODE,&wrq)<0) 63 if(iw_set_ext(skfd,(char *) device,SIOCSIWMODE,&wrq)<0)
64 { 64 {
65 wl_logerr("Could not set hostap card %s to raw mode, check cardtype", device); 65 wl_logerr("Could not set hostap card %s to raw mode, check cardtype", device);
66 return 0; 66 return 0;
67 } 67 }
68 else 68 else
69 { 69 {
@@ -100,13 +100,13 @@ int card_into_monitormode (pcap_t **orighandle, const char *device, int cardtype
100 100
101/* Check card is in the rfmon mode */ 101/* Check card is in the rfmon mode */
102int card_check_rfmon_datalink (const char *device) 102int card_check_rfmon_datalink (const char *device)
103{ 103{
104 int datalinktype=0; 104 int datalinktype=0;
105 pcap_t *phandle; 105 pcap_t *phandle;
106 phandle = pcap_open_live(device, 65,0,0,NULL); 106 phandle = pcap_open_live((char *)device, 65,0,0,NULL);
107 datalinktype = pcap_datalink (phandle); 107 datalinktype = pcap_datalink (phandle);
108 pcap_close(phandle); 108 pcap_close(phandle);
109 109
110 if (datalinktype != DLT_IEEE802_11) /* Rawmode is IEEE802_11 */ 110 if (datalinktype != DLT_IEEE802_11) /* Rawmode is IEEE802_11 */
111 { 111 {
112 return 0; 112 return 0;
@@ -213,13 +213,13 @@ int card_set_channel (const char *device, int channel, int cardtype)
213 { 213 {
214 int skfd; 214 int skfd;
215 skfd = socket(AF_INET, SOCK_STREAM, 0); 215 skfd = socket(AF_INET, SOCK_STREAM, 0);
216 struct iwreq wrq; 216 struct iwreq wrq;
217 iw_float2freq((double) channel, &wrq.u.freq); 217 iw_float2freq((double) channel, &wrq.u.freq);
218 218
219 if(iw_set_ext(skfd,device,SIOCSIWFREQ,&wrq)<0) 219 if(iw_set_ext(skfd,(char *) device,SIOCSIWFREQ,&wrq)<0)
220 { 220 {
221 wl_logerr("Could not set hostap card %s to channel %d", device, channel); 221 wl_logerr("Could not set hostap card %s to channel %d", device, channel);
222 return 0; 222 return 0;
223 } 223 }
224 else 224 else
225 { 225 {
@@ -266,13 +266,13 @@ int iw_get_range_info(int skfd, const char * ifname, iw_range * range)
266 /* Cleanup */ 266 /* Cleanup */
267 memset(buffer, 0, sizeof(buffer)); 267 memset(buffer, 0, sizeof(buffer));
268 wrq2.u.data.pointer = (caddr_t) buffer; 268 wrq2.u.data.pointer = (caddr_t) buffer;
269 wrq2.u.data.length = sizeof(buffer); 269 wrq2.u.data.length = sizeof(buffer);
270 wrq2.u.data.flags = 0; 270 wrq2.u.data.flags = 0;
271 271
272 if(iw_get_ext(skfd, ifname, SIOCGIWRANGE, &wrq2) < 0) 272 if(iw_get_ext(skfd, (char *)ifname, SIOCGIWRANGE, &wrq2) < 0)
273 { 273 {
274 wl_logerr("Could not get the range from the interface"); 274 wl_logerr("Could not get the range from the interface");
275 return(-1); 275 return(-1);
276 } 276 }
277 else 277 else
278 { 278 {