diff --git a/iiod-responder.c b/iiod-responder.c index d67d0d212..337c91343 100644 --- a/iiod-responder.c +++ b/iiod-responder.c @@ -13,6 +13,7 @@ #include #include #include +#include #include #ifdef _WIN32 #include @@ -158,9 +159,11 @@ static ssize_t iiod_rw_all(struct iiod_responder *priv, ret = priv->ops->read(priv->d, curr, nb); else ret = priv->ops->write(priv->d, curr, nb); - if (ret <= 0) + if (ret <= 0) { + printf("Got an error or stop event(%zd) (%lu)\n", ret, + pthread_self()); return ret; - + } while (ret && (size_t) ret >= curr->size) { ret -= curr->size; count += curr->size; diff --git a/iiod/ops.c b/iiod/ops.c index f34414a72..96c5dcf04 100644 --- a/iiod/ops.c +++ b/iiod/ops.c @@ -1593,6 +1593,7 @@ void ascii_interpreter(struct parser_pdata *pdata) int ret; yylex_init_extra(pdata, &scanner); + printf("ascii proto... binary=%d\n", pdata->binary); do { ret = yyparse(scanner);