Fixes for format errors (%lld <> int64_t)
Problem: beacon discovery was broken

Solution: fixed test of zpoller return value on timeout.