Home
last modified time | relevance | path

Searched refs:MALLOC (Results 1 – 25 of 36) sorted by relevance

12

/freebsd/contrib/libcbor/test/
H A Dcopy_test.c210 WITH_MOCK_MALLOC({ assert_null(cbor_copy(item)); }, 2, MALLOC, MALLOC_FAIL); in test_bytestring_chunk_alloc_failure()
224 MALLOC, MALLOC, MALLOC, MALLOC, REALLOC_FAIL); in test_bytestring_chunk_append_failure()
242 MALLOC, MALLOC, MALLOC, MALLOC, REALLOC, MALLOC_FAIL); in test_bytestring_second_chunk_alloc_failure()
262 WITH_MOCK_MALLOC({ assert_null(cbor_copy(item)); }, 2, MALLOC, MALLOC_FAIL); in test_string_chunk_alloc_failure()
275 MALLOC, MALLOC, MALLOC, MALLOC, REALLOC_FAIL); in test_string_chunk_append_failure()
291 MALLOC, MALLOC, MALLOC, MALLOC, REALLOC, MALLOC_FAIL); in test_string_second_chunk_alloc_failure()
313 MALLOC, MALLOC_FAIL); in test_array_item_alloc_failure()
326 MALLOC, MALLOC, REALLOC_FAIL); in test_array_push_failure()
340 MALLOC, MALLOC, REALLOC, MALLOC_FAIL); in test_array_second_item_alloc_failure()
367 MALLOC, MALLOC_FAIL); in test_map_key_alloc_failure()
[all …]
H A Darray_test.c170 WITH_MOCK_MALLOC({ assert_null(cbor_new_definite_array(42)); }, 2, MALLOC, in test_array_creation()
190 4, MALLOC, MALLOC, MALLOC, REALLOC_FAIL); in test_array_push()
204 4, MALLOC, MALLOC, MALLOC, REALLOC_FAIL); in test_indef_array_decode()
H A Dstring_test.c246 WITH_MOCK_MALLOC({ assert_null(cbor_new_indefinite_string()); }, 2, MALLOC, in test_string_add_chunk()
250 WITH_MOCK_MALLOC({ assert_null(cbor_build_string("Test")); }, 2, MALLOC, in test_string_add_chunk()
254 WITH_MOCK_MALLOC({ assert_null(cbor_build_stringn("Test", 4)); }, 2, MALLOC, in test_string_add_chunk()
273 5, MALLOC, MALLOC, MALLOC, MALLOC, REALLOC_FAIL); in test_add_chunk_reallocation_overflow()
H A Dmap_test.c215 WITH_MOCK_MALLOC({ assert_null(cbor_new_definite_map(42)); }, 2, MALLOC, in test_map_creation()
237 4, MALLOC, MALLOC, MALLOC, REALLOC_FAIL); in test_map_add()
251 4, MALLOC, MALLOC, MALLOC, REALLOC_FAIL); in test_indef_map_decode()
H A Dbytestring_test.c331 MALLOC, MALLOC_FAIL); in test_bytestring_creation()
336 WITH_MOCK_MALLOC({ assert_null(cbor_build_bytestring(bytes, 4)); }, 2, MALLOC, in test_bytestring_creation()
358 5, MALLOC, MALLOC, MALLOC, MALLOC, REALLOC_FAIL); in test_bytestring_add_chunk()
H A Dcallbacks_test.c120 MALLOC, MALLOC_FAIL); in test_builder_byte_string_callback_append_item_alloc_failure()
154 MALLOC, MALLOC, REALLOC_FAIL); in test_builder_byte_string_callback_append_parent_alloc_failure()
254 2, MALLOC, MALLOC_FAIL); in test_builder_string_callback_append_item_alloc_failure()
286 3, MALLOC, MALLOC, REALLOC_FAIL); in test_builder_string_callback_append_parent_alloc_failure()
H A Dtest_allocator.h10 MALLOC, enumerator
H A Dtest_allocator.c50 if (expectations[alloc_calls] == MALLOC) { in instrumented_malloc()
/freebsd/contrib/ntp/include/
H A Dparse.h66 #define MALLOC(_X_) (char *)kmem_alloc(_X_) macro
70 #define MALLOC(_X_) (char *)kmem_alloc(_X_, KM_SLEEP) macro
74 #define MALLOC(_X_) malloc(_X_) macro
/freebsd/contrib/nvi/common/
H A Dutil.c233 MALLOC(sp, copy, len + 1);
252 MALLOC(sp, copy, (len + 1) * sizeof(CHAR_T));
H A Dscreen.c90 MALLOC(sp, sp->newl, len); in screen_init()
H A Dcut.c293 MALLOC(sp, tp->lb, tp->lb_len); in text_init()
H A Drecover.c395 MALLOC(sp, host, hostmax + 1); in rcv_mailfile()
930 MALLOC(sp, data, dlen + len / 4 * 3 + 2);
/freebsd/contrib/gdtoa/
H A Dgdtoaimp.h212 #ifdef MALLOC
213 extern Char *MALLOC ANSI((size_t));
215 #define MALLOC malloc macro
H A Dg__fmt.c59 if ((decimalpoint_cache = (char*)MALLOC(strlen(s0) + 1))) {
H A Dchanges66 > * #define MALLOC your_malloc, where your_malloc(n) acts like malloc(n)
68 > * appropriate. If MALLOC is undefined, malloc will be invoked
71 > #ifndef MALLOC
72 > #define MALLOC malloc
78 > rv = (Bigint *)MALLOC(sizeof(Bigint) + (x-1)*sizeof(Long));
81 dtoa.c: if MALLOC is #defined, declare it.
540 to MALLOC.
542 MALLOC and FREE or free for huge blocks, which are possible only in
H A Dgethex.c60 if ((decimalpoint_cache = (char*)MALLOC(strlen(s0) + 1))) {
H A Dmisc.c66 rv = (Bigint *)MALLOC(sizeof(Bigint) + (x-1)*sizeof(ULong));
75 rv = (Bigint*)MALLOC(len*sizeof(double));
/freebsd/contrib/nvi/ex/
H A Dex_source.c64 MALLOC(sp, bp, (size_t)sb.st_size + 1); in ex_source()
H A Dex_subst.c230 MALLOC(sp, sp->repl, len * sizeof(CHAR_T)); in ex_s()
952 MALLOC(sp, *ptrnp, (plen + 1) * sizeof(CHAR_T)); in re_compile()
1288 MALLOC(sp, oe, s); in re_error()
/freebsd/contrib/nvi/vi/
H A Dv_match.c162 MALLOC(sp, *mp, len * sizeof(CHAR_T)); in v_buildmcs()
/freebsd/contrib/byacc/
H A Dmstring.c123 if ((n->base = n->ptr = MALLOC(HEAD)) != 0) in msnew()
/freebsd/contrib/ntp/libparse/
H A Dparse.c800 parse->parse_pdata = MALLOC(parse->parse_plen); in parse_setfmt()
817 parse->parse_data = (char*)MALLOC((unsigned)(parse->parse_dsize * 2 + 2)); in parse_setfmt()
/freebsd/contrib/expat/lib/
H A Dxmlparse.c761 #define MALLOC(parser, s) (parser->m_mem.malloc_fcn((s)))
1098 = (ATTRIBUTE *)MALLOC(parser, parser->m_attsSize * sizeof(ATTRIBUTE)); in parserCreate()
1104 parser->m_attInfo = (XML_AttrInfo *)MALLOC( in parserCreate()
1113 = (XML_Char *)MALLOC(parser, INIT_DATA_BUF_SIZE * sizeof(XML_Char)); in parserCreate()
2189 newBuf = (char *)MALLOC(parser, bufferSize); in XML_GetBuffer()
2397 return MALLOC(parser, size); in XML_MemRealloc()
2998 tag = (TAG *)MALLOC(parser, sizeof(TAG)); in doContent()
3001 tag->buf = (char *)MALLOC(parser, INIT_TAG_BUF_SIZE); in doContent()
3779 uri = (XML_Char *)MALLOC(parser, (n + EXPAND_SPARE) * sizeof(XML_Char)); in storeAtts()
4034 b = (BINDING *)MALLOC(parse in addBinding()
760 #define MALLOC( global() macro
[all...]
/freebsd/usr.sbin/route6d/
H A Droute6d.c263 #define MALLOC(type) ((type *)malloc(sizeof(type))) macro
1402 if ((rrt = MALLOC(struct riprt)) == NULL) { in riprecv()
1535 if ((ifcp = MALLOC(struct ifc)) == NULL) { in ifconfig()
1614 if ((ifac = MALLOC(struct ifac)) == NULL) { in ifconfig1()
2192 if ((rrt = MALLOC(struct riprt)) == NULL) in ifrt()
2343 if ((rrt = MALLOC(struct riprt)) == NULL) { in ifrt_p2p()
2715 if ((rrt = MALLOC(struct riprt)) == NULL) { in rt_entry()

12