Changes in uspace/srv/ns/service.c [96b02eb9:007e6efa] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/ns/service.c
r96b02eb9 r007e6efa 43 43 typedef struct { 44 44 link_t link; 45 sysarg_t service; /**< Number of the service. */45 sysarg_t service; /**< Service ID. */ 46 46 sysarg_t phone; /**< Phone registered with the service. */ 47 47 sysarg_t in_phone_hash; /**< Incoming phone hash. */ … … 56 56 * 57 57 */ 58 static hash_index_t service_hash(unsigned long *key)58 static hash_index_t service_hash(unsigned long key[]) 59 59 { 60 60 assert(key); 61 return ( *key% SERVICE_HASH_TABLE_CHAINS);61 return (key[0] % SERVICE_HASH_TABLE_CHAINS); 62 62 } 63 63 … … 86 86 87 87 if (keys == 2) 88 return ( key[1] == hs->in_phone_hash);88 return ((key[0] == hs->service) && (key[1] == hs->in_phone_hash)); 89 89 else 90 90 return (key[0] == hs->service); … … 195 195 hash_table_insert(&service_hash_table, keys, &hs->link); 196 196 197 return 0;197 return EOK; 198 198 } 199 199 … … 227 227 } 228 228 229 link_initialize(&pr->link); 229 230 pr->service = service; 230 231 pr->callid = callid;
Note:
See TracChangeset
for help on using the changeset viewer.