summaryrefslogtreecommitdiffstats
path: root/soltools/giparser
diff options
context:
space:
mode:
authorNikolai Pretzell <np@openoffice.org>2001-06-12 13:38:15 +0000
committerNikolai Pretzell <np@openoffice.org>2001-06-12 13:38:15 +0000
commit0b9c4226550b84530752da8e3222324cf623915b (patch)
treed6e613bccf7e18fd173921787edaef7b0a2c5979 /soltools/giparser
parentAdd default c'tor for List_GenericInfo iterators. (diff)
downloadcore-0b9c4226550b84530752da8e3222324cf623915b.tar.gz
core-0b9c4226550b84530752da8e3222324cf623915b.zip
Fix handling of empty ines.
Diffstat (limited to 'soltools/giparser')
-rw-r--r--soltools/giparser/gi_parse.cxx9
1 files changed, 5 insertions, 4 deletions
diff --git a/soltools/giparser/gi_parse.cxx b/soltools/giparser/gi_parse.cxx
index 5ba7060df7aa..4c56e10ab586 100644
--- a/soltools/giparser/gi_parse.cxx
+++ b/soltools/giparser/gi_parse.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: gi_parse.cxx,v $
*
- * $Revision: 1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: np $ $Date: 2001-06-11 16:04:51 $
+ * last change: $Author: np $ $Date: 2001-06-12 14:38:15 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -203,7 +203,7 @@ GenericInfo_Parser::ReadLine( istream & i_rSrc )
i_rSrc.get(sInput, nInputSize);
UINT32 nGot = UINT32(i_rSrc.gcount());
- if (nGot == 0)
+ if (nGot == 0 && i_rSrc.eof())
{
bGoon = false;
return;
@@ -257,7 +257,7 @@ GenericInfo_Parser::ClassifyLine()
case '{': return lt_open_list;
case '}': return lt_close_list;
case '#': return lt_comment;
- case '0': return lt_empty;
+ case '\0': return lt_empty;
}
return lt_key;
@@ -277,6 +277,7 @@ GenericInfo_Parser::ReadKey()
pSearch, strlen(pSearch),
sCurComment.str(), sCurComment.l()
);
+ sCurComment = "";
}
void