Hello HelenOS community,

I am sending a patch for Ctrl+C implementation. It does nothing more than
killing the current process.

Thanks,
Ashish

-- 
Ashish Kumar Gahlot
III year, UG
Govt. Engg. College, Ajmer, India
=== modified file 'uspace/lib/clui/tinput.c'
--- uspace/lib/clui/tinput.c	2015-10-20 10:08:15 +0000
+++ uspace/lib/clui/tinput.c	2017-03-29 13:58:38 +0000
@@ -41,6 +41,7 @@
 #include <assert.h>
 #include <stdbool.h>
 #include <tinput.h>
+#include <task.h>
 
 #define LIN_TO_COL(ti, lpos) ((lpos) % ((ti)->con_cols))
 #define LIN_TO_ROW(ti, lpos) ((lpos) / ((ti)->con_cols))
@@ -950,8 +951,8 @@
 		tinput_sel_delete(ti);
 		break;
 	case KC_C:
-		tinput_sel_copy_to_cb(ti);
-		break;
+		printf("\n^C");
+		task_kill(task_get_id());
 	case KC_V:
 		tinput_sel_delete(ti);
 		tinput_paste_from_cb(ti);

=== modified file 'uspace/lib/clui/Makefile'
--- uspace/lib/clui/Makefile	2015-06-21 12:08:45 +0000
+++ uspace/lib/clui/Makefile	2017-03-29 13:41:05 +0000
@@ -27,7 +27,7 @@
 #
 
 USPACE_PREFIX = ../..
-EXTRA_CFLAGS = -I.
+EXTRA_CFLAGS = -I. -Iinclude/
 LIBRARY = libclui
 
 SOURCES = \

_______________________________________________
HelenOS-devel mailing list
[email protected]
http://lists.modry.cz/listinfo/helenos-devel

Reply via email to