Check for denied access in itemdef/nodedef/media fetch loop
authorKahrl <kahrl@gmx.net>
Thu, 19 Dec 2013 20:47:08 +0000 (21:47 +0100)
committerKahrl <kahrl@gmx.net>
Thu, 19 Dec 2013 20:47:08 +0000 (21:47 +0100)
src/game.cpp

index 6f48870ad37ea9fb252b02aef2e48a24b7e2f715..8cf7da1e160f9af79c5adf93a2f1ef880fc7b7b9 100644 (file)
@@ -1215,6 +1215,12 @@ void the_game(
                                break;
                        }
                        // Break conditions
+                       if(client.accessDenied()){
+                               error_message = L"Access denied. Reason: "
+                                               +client.accessDeniedReason();
+                               errorstream<<wide_to_narrow(error_message)<<std::endl;
+                               break;
+                       }
                        if(!client.connectedAndInitialized()){
                                error_message = L"Client disconnected";
                                errorstream<<wide_to_narrow(error_message)<<std::endl;