> -err:
> - if (rc < 0)
> - return rc;
> -
> return tmp - buf;
> +
> +err:
> + return -E2BIG;
We finally fixed this bug! Hooray! But it's like you guys are
deliberately writing in terrible style. You can just return directly
and then you would have avoided this bug
From: Dmitry Eremin
Currently both cfs_cpt_table_print() and cfs_cpt_distance_print()
handle the error path in a confusing way. Simplify it so it just
returns E2BIG on failure instead of testing rc value before
exiting.
Signed-off-by: Dmitry Eremin