fix errors
[carveJwlIkooP6JGAAIwe30JlM.git] / world_routes.c
index 75ebae8af66a92afdc58d81eb1f6971d3ba89cb1..f4de14c9786792985958bbea4a8d45f59f3011c3 100644 (file)
@@ -932,12 +932,14 @@ static void world_routes_recv_scoreboard( world_instance *world,
    struct leaderboard_cache *board = &world->leaderboard_cache[ route_id ];
    board->status = status;
 
-   if( body == NULL )
+   if( body == NULL ){
       board->data_len = 0;
+      return;
+   }
 
-   if( body->max > NETWORK_LEADERBOARD_MAX_SIZE ){
+   if( body->max > NETWORK_REQUEST_MAX ){
       vg_error( "Scoreboard leaderboard too big (%u>%u)\n", body->max,
-                NETWORK_LEADERBOARD_MAX_SIZE );
+                NETWORK_REQUEST_MAX );
       return;
    }