ucx/properties.c

branch
dav-2
changeset 886
da79af4baec8
parent 854
1c8401ece69e
child 889
42cdbf9bbd49
equal deleted inserted replaced
885:591377a27fa3 886:da79af4baec8
285 285
286 static int cx_properties_read_init_file( 286 static int cx_properties_read_init_file(
287 cx_attr_unused CxProperties *prop, 287 cx_attr_unused CxProperties *prop,
288 CxPropertiesSource *src 288 CxPropertiesSource *src
289 ) { 289 ) {
290 src->data_ptr = malloc(src->data_size); 290 src->data_ptr = cxMallocDefault(src->data_size);
291 if (src->data_ptr == NULL) return 1; 291 if (src->data_ptr == NULL) return 1;
292 return 0; 292 return 0;
293 } 293 }
294 294
295 static void cx_properties_read_clean_file( 295 static void cx_properties_read_clean_file(
296 cx_attr_unused CxProperties *prop, 296 cx_attr_unused CxProperties *prop,
297 CxPropertiesSource *src 297 CxPropertiesSource *src
298 ) { 298 ) {
299 free(src->data_ptr); 299 cxFreeDefault(src->data_ptr);
300 } 300 }
301 301
302 CxPropertiesSource cxPropertiesStringSource(cxstring str) { 302 CxPropertiesSource cxPropertiesStringSource(cxstring str) {
303 CxPropertiesSource src; 303 CxPropertiesSource src;
304 src.src = (void*) str.ptr; 304 src.src = (void*) str.ptr;

mercurial