Fixes comparisons for POSIX standard dash/sh

Fixes issue #28 as well