Skip to content

Commit

Permalink
respondd-module-wifi: replace mac_addr_n2a implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
genofire committed Sep 25, 2018
1 parent 0376376 commit f703626
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions net/respondd-module-wifi/src/netlink.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,7 @@


void mac_addr_n2a(char *mac_addr, unsigned char *arg) {
int i, l;

l = 0;
for (i = 0; i < ETH_ALEN ; i++) {
if (i == 0) {
sprintf(mac_addr+l, "%02x", arg[i]);
l += 2;
} else {
sprintf(mac_addr+l, ":%02x", arg[i]);
l += 3;
}
}
sprintf(mac_addr, "%02x:%02x:%02x:%02x:%02x:%02x", arg[0], arg[1], arg[2], arg[3], arg[4], arg[5]);
}


Expand Down

0 comments on commit f703626

Please sign in to comment.