Fix sign_extend()

We need to shift as many bits to the right as we shift to the left.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>