iio: Accept a leading '+' sign when parsing fixed point numbers
If we encounter a leading '+' sign just skip over it. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
This commit is contained in:
parent
02330acda7
commit
ef4f92c064
|
@ -437,6 +437,8 @@ static ssize_t iio_write_channel_info(struct device *dev,
|
|||
if (buf[0] == '-') {
|
||||
negative = true;
|
||||
buf++;
|
||||
} else if (buf[0] == '+') {
|
||||
buf++;
|
||||
}
|
||||
|
||||
while (*buf) {
|
||||
|
|
Loading…
Reference in New Issue