From 22a22c1de85a0112837e1dc48a3307b79bb44210 Mon Sep 17 00:00:00 2001 From: Jan Nieuwenhuizen Date: Sun, 17 Jun 2018 14:17:39 +0200 Subject: [PATCH] mescc: Support binutils 2.25: fseek: Add debug printing. * lib/libc+tcc.c (fseek): Add debug printing. --- lib/libc+tcc.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/libc+tcc.c b/lib/libc+tcc.c index 5832f7a9..d1133d40 100644 --- a/lib/libc+tcc.c +++ b/lib/libc+tcc.c @@ -277,6 +277,11 @@ int fseek (FILE *stream, long offset, int whence) { int pos = lseek ((int)stream, offset, whence); + if (__mes_debug ()) + { + eputs ("fread fd="); eputs (itoa ((int)stream)); + eputs (" =>"); eputs (itoa (pos)); eputs ("\n"); + } if (pos >= 0) return 0; return -1;