diff options
Diffstat (limited to 'src/kernel')
-rw-r--r-- | src/kernel/ipc/request.c | 6 | ||||
-rw-r--r-- | src/kernel/ipc/request.h | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/src/kernel/ipc/request.c b/src/kernel/ipc/request.c index e59a66c..4e8b407 100644 --- a/src/kernel/ipc/request.c +++ b/src/kernel/ipc/request.c @@ -20,7 +20,11 @@ int request_get(int id, uint32_t ptr, int wait) { //when request pending (wait finished), write it to ptr struct user_request *p = (struct user_request*)ptr; p->func = obj->request->func; - for (i = 0; i < 3; i++) p->params[i] = obj->request->params[i]; + for (i = 0; i < 3; i++) { + p->params[i] = obj->request->params[i]; + if (obj->request->shm_sndr[i] != 0) p->shmsize[i] = obj->request->shm_sndr[i]->len; + else p->shmsize[i] = 0; + } p->isBlocking = (obj->request->requester != 0); //if request is nonblocking and no shm is to be mapped, delete request and unlock objects busymutex, else set it to acknowledged if (p->isBlocking) return 0; diff --git a/src/kernel/ipc/request.h b/src/kernel/ipc/request.h index 0afc48b..b08264f 100644 --- a/src/kernel/ipc/request.h +++ b/src/kernel/ipc/request.h @@ -28,7 +28,7 @@ struct request { }; struct user_request { - uint32_t func, params[3]; + uint32_t func, params[3], shmsize[3]; int isBlocking; // 1 : blocking request, 0 : nonblocking request (message) }; |