diff options
| author | Filippos Karapetis | 2010-06-14 12:44:57 +0000 |
|---|---|---|
| committer | Filippos Karapetis | 2010-06-14 12:44:57 +0000 |
| commit | cd77cb96fc85ba2f681337630c4374ce0565927f (patch) | |
| tree | 01a533bfc4c41c3ea63d100b6ab933ba2b880dcc /engines/sci/engine/seg_manager.cpp | |
| parent | b921cebce882de6d32ed3fd62de16ee215daa467 (diff) | |
| download | scummvm-rg350-cd77cb96fc85ba2f681337630c4374ce0565927f.tar.gz scummvm-rg350-cd77cb96fc85ba2f681337630c4374ce0565927f.tar.bz2 scummvm-rg350-cd77cb96fc85ba2f681337630c4374ce0565927f.zip | |
Some cleanup of the script locals code
svn-id: r49649
Diffstat (limited to 'engines/sci/engine/seg_manager.cpp')
| -rw-r--r-- | engines/sci/engine/seg_manager.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/sci/engine/seg_manager.cpp b/engines/sci/engine/seg_manager.cpp index 4d3e6f754e..8d51b27099 100644 --- a/engines/sci/engine/seg_manager.cpp +++ b/engines/sci/engine/seg_manager.cpp @@ -377,8 +377,8 @@ SegmentId SegManager::getScriptSegment(int script_nr, ScriptLoadType load) { return segment; } -LocalVariables *SegManager::allocLocalsSegment(Script *scr, int count) { - if (!count) { // No locals +LocalVariables *SegManager::allocLocalsSegment(Script *scr) { + if (!scr->getLocalsCount()) { // No locals scr->_localsSegment = 0; scr->_localsBlock = NULL; return NULL; @@ -395,7 +395,7 @@ LocalVariables *SegManager::allocLocalsSegment(Script *scr, int count) { scr->_localsBlock = locals; locals->script_id = scr->_nr; - locals->_locals.resize(count); + locals->_locals.resize(scr->getLocalsCount()); return locals; } |
