Hey there,
The reason it will show up the login pop-up is because the system detected the current log in user has logged out already as the easysocial's script will send a request to the server for retrieving the current user whether got any new message, friend request and system notification or not.
Since system detected the 'current log in user' has logged out already, so it will require the user to login in order to send this request to the server automatically, this is why system shows the login pop up at this point of time.