localzone.c (366095) | localzone.c (368693) |
---|---|
1/* 2 * services/localzone.c - local zones authority service. 3 * 4 * Copyright (c) 2007, NLnet Labs. All rights reserved. 5 * 6 * This software is open source. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 143 unchanged lines hidden (view full) --- 152 } 153 z->node.key = z; 154 z->dclass = dclass; 155 z->type = t; 156 z->name = nm; 157 z->namelen = len; 158 z->namelabs = labs; 159 lock_rw_init(&z->lock); | 1/* 2 * services/localzone.c - local zones authority service. 3 * 4 * Copyright (c) 2007, NLnet Labs. All rights reserved. 5 * 6 * This software is open source. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 143 unchanged lines hidden (view full) --- 152 } 153 z->node.key = z; 154 z->dclass = dclass; 155 z->type = t; 156 z->name = nm; 157 z->namelen = len; 158 z->namelabs = labs; 159 lock_rw_init(&z->lock); |
160 z->region = regional_create_custom(sizeof(struct regional)); | 160 z->region = regional_create_nochunk(sizeof(struct regional)); |
161 if(!z->region) { 162 free(z); 163 return NULL; 164 } 165 rbtree_init(&z->data, &local_data_cmp); 166 lock_protect(&z->lock, &z->parent, sizeof(*z)-sizeof(rbnode_type)); 167 /* also the zones->lock protects node, parent, name*, class */ 168 return z; --- 1843 unchanged lines hidden --- | 161 if(!z->region) { 162 free(z); 163 return NULL; 164 } 165 rbtree_init(&z->data, &local_data_cmp); 166 lock_protect(&z->lock, &z->parent, sizeof(*z)-sizeof(rbnode_type)); 167 /* also the zones->lock protects node, parent, name*, class */ 168 return z; --- 1843 unchanged lines hidden --- |