fix a bug in escape.c