Fix strncmp length usage

Change-Id: I71f461c3ffb60cbaece6595f480538adb016bffc