WhatsApp online status bug? Recently I sent a whatsApp chat message to an android smartphone when it was shutdown. 
Few seconds after the message was marked with only one flag (message sent but not delivered), 
I've seen the online status appearing then after 10 second  disappearing.
Do you thing this is a WhatsApp bug or a compromised WhatsApp account?
To record an online status, the WhatsApp client (the app in device) pings the server once a few seconds (maybe once 10 seconds or something, IDK) to mark that it's alive and connected. If the server doesn't receive a message from the client within that keep-alive timeout, the client will be marked offline.. 

The timeout (or frequency of sending alive packet) is kept large like this because to avoid flooding the server with pings. Also, it takes time for the offline status to be recorded in the database.. Hence the delay. This is not a bug, this is just how it works..