replaced strings with const char * to improve portability