From fbfc078e9f44c1c1e95c9c484f1d5650bcf631b7 Mon Sep 17 00:00:00 2001 From: Benji Dial Date: Sat, 27 Jul 2024 16:57:39 -0400 Subject: lots and lots of userspace stuff --- kernel/source/application.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'kernel/source/application.cpp') diff --git a/kernel/source/application.cpp b/kernel/source/application.cpp index 0c3fd36..8070019 100644 --- a/kernel/source/application.cpp +++ b/kernel/source/application.cpp @@ -239,7 +239,7 @@ namespace hilbert::kernel::application { void thread::wait_for_socket_stream(socket_stream_end *the_socket_stream) { waiting_for_socket_stream = the_socket_stream; the_socket_stream->waiting_to_read.insert(this); - yield(); + yield(saved_state); waiting_for_socket_stream = 0; } @@ -247,7 +247,7 @@ namespace hilbert::kernel::application { socket_listener *the_socket_listener) { waiting_to_accept_from = the_socket_listener; the_socket_listener->waiting_to_accept.insert(this); - yield(); + yield(saved_state); waiting_to_accept_from = 0; return new_socket_stream_id; } @@ -256,15 +256,15 @@ namespace hilbert::kernel::application { socket_listener *the_socket_listener) { waiting_to_connect_to = the_socket_listener; the_socket_listener->waiting_to_connect.insert(this); - yield(); + yield(saved_state); waiting_to_connect_to = 0; return new_socket_stream_id; } void thread::wait_for_input() { - waiting_for_input = false; + waiting_for_input = true; input::waiting_for_input->insert(this); - yield(); + yield(saved_state); waiting_for_input = false; } -- cgit v1.2.3