shithub: drawterm-fdroid

Download patch

ref: 8bd7505dc37201cbcb99bf4e6b48d938af64bb5b
parent: 3a32c0713dc419c1c7fafc56cbf3d83af832a391
author: cinap_lenrek <[email protected]>
date: Sun May 29 21:14:33 EDT 2016

devcons: simplify line editing logic

--- a/kern/devcons.c
+++ b/kern/devcons.c
@@ -626,14 +626,13 @@
 					case 0x15:
 						kbd.x = 0;
 						break;
+					case '\n':
+						kbd.x++;
 					case 0x04:
 						eol = 1;
 						break;
-					case '\n':
-						eol = 1;
 					default:
-						kbd.line[kbd.x++] = ch;
-						break;
+						kbd.x++;
 					}
 				}
 				if(kbd.x == sizeof(kbd.line) || eol){