add_history(cs_answer);
}
- if(!cs_answer){
- //Transfor answer into cstring
+ if(!cs_answer){ //In case of an EOF
CleanStringVariable(answer, 1);
*result = (CleanString) answer;
memcpy(CleanStringCharacters(answer), "", 1);
CleanStringLength(answer) = 1;
- } else {
- //Transfor answer into cstring
+ } else { //In case of a proper response
CleanStringVariable(answer, strlen(cs_answer));
*result = (CleanString) answer;
memcpy(CleanStringCharacters(answer), cs_answer, strlen(cs_answer));