Changeset 8b655705 in mainline for uspace/lib/packet/generic/packet_server.c
- Timestamp:
- 2011-04-15T19:38:07Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 9dd730d1
- Parents:
- 6b9e85b (diff), b2fb47f (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/packet/generic/packet_server.c
r6b9e85b r8b655705 44 44 #include <unistd.h> 45 45 #include <sys/mman.h> 46 47 #include <ipc/ipc.h>48 46 #include <ipc/packet.h> 49 47 #include <ipc/net.h> 50 51 48 #include <net/packet.h> 52 49 #include <net/packet_header.h> … … 115 112 size_t max_content, size_t max_suffix) 116 113 { 117 / / clear the packet content114 /* Clear the packet content */ 118 115 bzero(((void *) packet) + sizeof(packet_t), 119 116 packet->length - sizeof(packet_t)); 120 117 121 / / clear the packet header118 /* Clear the packet header */ 122 119 packet->order = 0; 123 120 packet->metric = 0; … … 154 151 assert(fibril_mutex_is_locked(&ps_globals.lock)); 155 152 156 / / already locked153 /* Already locked */ 157 154 packet = (packet_t *) mmap(NULL, length, PROTO_READ | PROTO_WRITE, 158 155 MAP_SHARED | MAP_ANONYMOUS, 0, 0); … … 292 289 293 290 if (!async_share_in_receive(&callid, &size)) { 294 ipc_answer_0(callid, EINVAL);291 async_answer_0(callid, EINVAL); 295 292 return EINVAL; 296 293 } 297 294 298 295 if (size != packet->length) { 299 ipc_answer_0(callid, ENOMEM);296 async_answer_0(callid, ENOMEM); 300 297 return ENOMEM; 301 298 }
Note:
See TracChangeset
for help on using the changeset viewer.