[sdk] Modified option parsing loop

Signed-off-by: Juha Kallioinen <juha.kallioinen@jollamobile.com>