D'oh. Use %d, not %u for printf signed ints.
add unsigned int w:1 to struct