diff options
| author | Strangerke | 2014-11-18 12:10:07 +0100 | 
|---|---|---|
| committer | Paul Gilbert | 2014-12-12 22:34:33 -0500 | 
| commit | 8e483e037f1851fb96fd2125bf526828cdfa6e98 (patch) | |
| tree | 8da7f16648b29b178d95898298a879de669e8473 | |
| parent | 44e7051b955b7ccf12da6a8bfdbca2155f296a98 (diff) | |
| download | scummvm-rg350-8e483e037f1851fb96fd2125bf526828cdfa6e98.tar.gz scummvm-rg350-8e483e037f1851fb96fd2125bf526828cdfa6e98.tar.bz2 scummvm-rg350-8e483e037f1851fb96fd2125bf526828cdfa6e98.zip | |
ACCESS: Fix the handling of the very last line of a text in getLine
| -rw-r--r-- | engines/access/font.cpp | 5 | 
1 files changed, 4 insertions, 1 deletions
| diff --git a/engines/access/font.cpp b/engines/access/font.cpp index 5eaf0b0ca8..5686cdf3b0 100644 --- a/engines/access/font.cpp +++ b/engines/access/font.cpp @@ -110,8 +110,11 @@ bool Font::getLine(Common::String &s, int maxWidth, Common::String &line, int &w  		// Reached maximum allowed size  		// If this was the last character of the string, let it go -		if (*src == '\0') +		if (*src == '\0') { +			line = Common::String(s.c_str(), src); +			s = "";  			return true; +		}  		// Work backwards to find space at the start of the current word   		// as a point to split the line on | 
