From 2b475288859e894785e20775a6c8d7b9b95c881c Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Sat, 14 Mar 2009 18:49:52 +0100 Subject: [PATCH] ted plugin: Don't expect a minimum length. The serial interface apparently can only deliver 255 bytes at once, so checking if we received ``enough'' (i. e. 278+x) bytes will never work. --- src/ted.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/ted.c b/src/ted.c index 57c88898..d2a73a53 100644 --- a/src/ted.c +++ b/src/ted.c @@ -154,13 +154,6 @@ static int ted_read_value(double *ret_power, double *ret_voltage) receive_buffer_length); return (-1); } - else if (receive_buffer_length < EXPECTED_PACKAGE_LENGTH) - { - WARNING ("ted plugin: read(2) returned %zi bytes, " - "but at least %i are necessary for a valid packet.", - receive_buffer_length, EXPECTED_PACKAGE_LENGTH); - return (-1); - } /* * packet filter loop -- 2.11.0