diff options
| author | Colin Snover | 2017-01-05 21:05:22 -0600 | 
|---|---|---|
| committer | Colin Snover | 2017-02-05 12:38:21 -0600 | 
| commit | 10d97ce37947362e6fa7161cd85221f59ca49490 (patch) | |
| tree | 096af451474abe5ab3f65e61016a0ff2d413608c /engines/sci/engine/kstring.cpp | |
| parent | b1c3332fddbb16838f1a654d6fe35ddbe09bd051 (diff) | |
| download | scummvm-rg350-10d97ce37947362e6fa7161cd85221f59ca49490.tar.gz scummvm-rg350-10d97ce37947362e6fa7161cd85221f59ca49490.tar.bz2 scummvm-rg350-10d97ce37947362e6fa7161cd85221f59ca49490.zip | |
SCI: Fix more unsafe C-string usage
Diffstat (limited to 'engines/sci/engine/kstring.cpp')
| -rw-r--r-- | engines/sci/engine/kstring.cpp | 2 | 
1 files changed, 1 insertions, 1 deletions
| diff --git a/engines/sci/engine/kstring.cpp b/engines/sci/engine/kstring.cpp index ae91ef088a..4c5f1228de 100644 --- a/engines/sci/engine/kstring.cpp +++ b/engines/sci/engine/kstring.cpp @@ -305,7 +305,7 @@ reg_t kFormat(EngineState *s, int argc, reg_t *argv) {  				Common::String tempsource = g_sci->getKernel()->lookupText(reg,  				                                  arguments[paramindex + 1]); -				int slen = strlen(tempsource.c_str()); +				int slen = tempsource.size();  				int extralen = strLength - slen;  				assert((target - targetbuf) + extralen <= maxsize);  				if (extralen < 0) | 
