projects
/
supertux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix compiler errors
[supertux.git]
/
src
/
lisp
/
lexer.cpp
diff --git
a/src/lisp/lexer.cpp
b/src/lisp/lexer.cpp
index
ef1925f
..
cd4ab64
100644
(file)
--- a/
src/lisp/lexer.cpp
+++ b/
src/lisp/lexer.cpp
@@
-34,8
+34,8
@@
Lexer::Lexer(std::istream& newstream) :
token_length()
{
// trigger a refill of the buffer
token_length()
{
// trigger a refill of the buffer
- bufpos =
'\0'
;
- bufend =
'\0'
;
+ bufpos =
NULL
;
+ bufend =
NULL
;
nextChar();
}
nextChar();
}
@@
-46,7
+46,7
@@
Lexer::~Lexer()
void
Lexer::nextChar()
{
void
Lexer::nextChar()
{
- if(bufpos >= bufend) {
+ if(bufpos >= bufend
|| (bufpos == NULL && bufend == NULL) /* Initial refill trigger */
) {
if(eof) {
c = EOF;
return;
if(eof) {
c = EOF;
return;