more fixes mainly pcap/sock problems