fixes to Linux dev_t macros
different connect behaviour in BSD