fix crash with error inset

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@1945 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2001-04-20 13:18:09 +00:00
parent 664eb7ff45
commit aab6ddd2e5
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2001-04-20 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
* xforms_helpers.C (formatted): do not use string::substr(1) on a
string of length 1 !
2001-04-16 Allan Rae <rae@lyx.org>
* xforms_helpers.C (formatted):

View File

@ -71,7 +71,7 @@ string formatted(string const & sin, int w, int size, int style)
char c = word[0];
if (c == '\n') {
sout += line + '\n';
word = word.substr(1);
word.erase(0,1);
line_plus_word.erase();
line.erase();
}