nusb/ether: fix pointer truncation

This commit is contained in:
cinap_lenrek 2014-02-14 14:18:09 +01:00
parent dd4a487b0e
commit fc78640118

View file

@ -91,7 +91,7 @@ static char *uname;
#define PATH(type, n) ((type)|((n)<<8)) #define PATH(type, n) ((type)|((n)<<8))
#define TYPE(path) (((uint)(path) & 0x000000FF)>>0) #define TYPE(path) (((uint)(path) & 0x000000FF)>>0)
#define NUM(path) (((uint)(path) & 0xFFFFFF00)>>8) #define NUM(path) (((uint)(path) & 0xFFFFFF00)>>8)
#define NUMCONN(c) (((long)(c)-(long)&conn[0])/sizeof(conn[0])) #define NUMCONN(c) (((uintptr)(c)-(uintptr)&conn[0])/sizeof(conn[0]))
static void static void
fillstat(Dir *d, uvlong path) fillstat(Dir *d, uvlong path)