diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2013-06-10 21:24:15 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2013-06-10 21:24:15 +0300 |
commit | 1fe7f64c13e8994b73a5da3f5582de5b4850bfa2 (patch) | |
tree | 296b5eedbde7eb776492c650e2a9d416961d181b /debug.c | |
parent | d52d17b46e53bb0d4a991cd32f859eb349d3b101 (diff) | |
download | egawk-1fe7f64c13e8994b73a5da3f5582de5b4850bfa2.tar.gz egawk-1fe7f64c13e8994b73a5da3f5582de5b4850bfa2.tar.bz2 egawk-1fe7f64c13e8994b73a5da3f5582de5b4850bfa2.zip |
Bug fix for debugger under Windows.
Diffstat (limited to 'debug.c')
-rw-r--r-- | debug.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -519,6 +519,9 @@ print_lines(char *src, int start_line, int nlines) return -1; } + /* set binary mode so that byte offset calculations will be right */ + os_setbinmode(s->fd, O_BINARY); + if (fstat(s->fd, &sbuf) == 0 && s->mtime < sbuf.st_mtime) { fprintf(out_fp, _("WARNING: source file `%s' modified since program compilation.\n"), src); @@ -534,6 +537,7 @@ print_lines(char *src, int start_line, int nlines) src, strerror(errno)); return -1; } + os_setbinmode(s->fd, O_BINARY); } if (s->line_offset == NULL && find_lines(s) != 0) |