Fix wrong return values.

Lesson learned: do not write code before morning coffee.

Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>