fix bug in finding mac address