Rev 2927 | Rev 3149 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2927 | Rev 2948 | ||
---|---|---|---|
Line 241... | Line 241... | ||
241 | /* The recipient agreed to send data. */ |
241 | /* The recipient agreed to send data. */ |
242 | uintptr_t src = IPC_GET_ARG1(answer->data); |
242 | uintptr_t src = IPC_GET_ARG1(answer->data); |
243 | uintptr_t dst = IPC_GET_ARG1(*olddata); |
243 | uintptr_t dst = IPC_GET_ARG1(*olddata); |
244 | size_t max_size = IPC_GET_ARG2(*olddata); |
244 | size_t max_size = IPC_GET_ARG2(*olddata); |
245 | size_t size = IPC_GET_ARG2(answer->data); |
245 | size_t size = IPC_GET_ARG2(answer->data); |
246 | if (size <= max_size) { |
246 | if (size && size <= max_size) { |
247 | /* |
247 | /* |
248 | * Copy the destination VA so that this piece of |
248 | * Copy the destination VA so that this piece of |
249 | * information is not lost. |
249 | * information is not lost. |
250 | */ |
250 | */ |
251 | IPC_SET_ARG1(answer->data, dst); |
251 | IPC_SET_ARG1(answer->data, dst); |
Line 256... | Line 256... | ||
256 | if (rc) { |
256 | if (rc) { |
257 | IPC_SET_RETVAL(answer->data, rc); |
257 | IPC_SET_RETVAL(answer->data, rc); |
258 | free(answer->buffer); |
258 | free(answer->buffer); |
259 | answer->buffer = NULL; |
259 | answer->buffer = NULL; |
260 | } |
260 | } |
- | 261 | } else if (!size) { |
|
- | 262 | IPC_SET_RETVAL(answer->data, EOK); |
|
261 | } else { |
263 | } else { |
262 | IPC_SET_RETVAL(answer->data, ELIMIT); |
264 | IPC_SET_RETVAL(answer->data, ELIMIT); |
263 | } |
265 | } |
264 | } |
266 | } |
265 | } else if (IPC_GET_METHOD(*olddata) == IPC_M_DATA_WRITE) { |
267 | } else if (IPC_GET_METHOD(*olddata) == IPC_M_DATA_WRITE) { |