why not just strcmp(buffer, "VOK")?  "VOK" guarantees the null termination and buffer is much larger.