diff options
author | Ossama Othman <ossama-othman@users.noreply.github.com> | 2007-02-21 22:29:49 +0000 |
---|---|---|
committer | Ossama Othman <ossama-othman@users.noreply.github.com> | 2007-02-21 22:29:49 +0000 |
commit | f11224da696a623a28510aafb10532ca999be51b (patch) | |
tree | 63afe56dbcdb765415669eeb73315cf45b03b9ca /ACE/ace/Svc_Conf_Lexer.cpp | |
parent | cc970acff36ed652b93a32c8074558c310349658 (diff) | |
download | ATCD-f11224da696a623a28510aafb10532ca999be51b.tar.gz |
ChangeLogTag:Wed Feb 21 19:27:14 UTC 2007 Ossama Othman <ossama_othman at symantec dot com>
Diffstat (limited to 'ACE/ace/Svc_Conf_Lexer.cpp')
-rw-r--r-- | ACE/ace/Svc_Conf_Lexer.cpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/ACE/ace/Svc_Conf_Lexer.cpp b/ACE/ace/Svc_Conf_Lexer.cpp index 2f8ced577f2..3bcd8d6d559 100644 --- a/ACE/ace/Svc_Conf_Lexer.cpp +++ b/ACE/ace/Svc_Conf_Lexer.cpp @@ -329,13 +329,16 @@ ACE_Svc_Conf_Lexer::scan (ACE_YYSTYPE* ace_yylval, // Now, we need to move back in the string until we find the // same character that started the string bool string_end_found = false; - for(ssize_t i = (current - 1) - buffer->index_; i >= 0; i--) + if (current > buffer->index_) { - if (source[i] == buffer->string_start_) + for (size_t i = current - buffer->index_; i-- != 0; ) { - current = buffer->index_ + i + 1; - string_end_found = true; - break; + if (source[i] == buffer->string_start_) + { + current = buffer->index_ + i + 1; + string_end_found = true; + break; + } } } |