Fix resolution changing code - last call to strtok needs to have NULL
as first param