Throttle.cc (6372:f1a41ea3bbab) | Throttle.cc (6493:1fa51760a963) |
---|---|
1 2/* 3 * Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions are 8 * met: redistributions of source code must retain the above copyright --- 261 unchanged lines hidden (view full) --- 270static 271int network_message_to_size(NetworkMessage* net_msg_ptr) 272{ 273 assert(net_msg_ptr != NULL); 274 275 // Artificially increase the size of broadcast messages 276 if (BROADCAST_SCALING > 1) { 277 if (net_msg_ptr->getDestination().isBroadcast()) { | 1 2/* 3 * Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions are 8 * met: redistributions of source code must retain the above copyright --- 261 unchanged lines hidden (view full) --- 270static 271int network_message_to_size(NetworkMessage* net_msg_ptr) 272{ 273 assert(net_msg_ptr != NULL); 274 275 // Artificially increase the size of broadcast messages 276 if (BROADCAST_SCALING > 1) { 277 if (net_msg_ptr->getDestination().isBroadcast()) { |
278 return (MessageSizeType_to_int(net_msg_ptr->getMessageSize()) * MESSAGE_SIZE_MULTIPLIER * BROADCAST_SCALING); | 278 return (RubySystem::getNetwork()->MessageSizeType_to_int(net_msg_ptr->getMessageSize()) * MESSAGE_SIZE_MULTIPLIER * BROADCAST_SCALING); |
279 } 280 } | 279 } 280 } |
281 return (MessageSizeType_to_int(net_msg_ptr->getMessageSize()) * MESSAGE_SIZE_MULTIPLIER); | 281 return (RubySystem::getNetwork()->MessageSizeType_to_int(net_msg_ptr->getMessageSize()) * MESSAGE_SIZE_MULTIPLIER); |
282} | 282} |