main.c
changeset 744 628c5bac7f3b
parent 740 1cb9ae0a0104
child 757 22dfaeb82491
equal deleted inserted replaced
743:cb8b18d787d0 744:628c5bac7f3b
   271 				strncpy(stext, "EOF", 4);
   271 				strncpy(stext, "EOF", 4);
   272 				readin = False;
   272 				readin = False;
   273 				break;
   273 				break;
   274 			default:
   274 			default:
   275 				for(stext[r] = '\0', p = stext + strlen(stext) - 1; p >= stext && *p == '\n'; *p-- = '\0');
   275 				for(stext[r] = '\0', p = stext + strlen(stext) - 1; p >= stext && *p == '\n'; *p-- = '\0');
   276 				for(p = stext + strlen(stext) - 1; p >= stext && *p != '\n'; --p);
   276 				for(; p >= stext && *p != '\n'; --p);
   277 				if(p > stext)
   277 				if(p > stext)
   278 					strncpy(stext, p + 1, sizeof stext);
   278 					strncpy(stext, p + 1, sizeof stext);
   279 			}
   279 			}
   280 			drawstatus();
   280 			drawstatus();
   281 		}
   281 		}