Lines Matching refs:bufref
28 static struct bufref bufref; variable
41 Curl_bufref_init(&bufref); in unit_setup()
47 Curl_bufref_free(&bufref); in unit_stop()
63 fail_unless(!bufref.ptr, "Initial reference must be NULL");
64 fail_unless(!bufref.len, "Initial length must be NULL");
65 fail_unless(!bufref.dtor, "Destructor must be NULL");
73 Curl_bufref_set(&bufref, buffer, 13, test_free);
75 fail_unless((char *) bufref.ptr == buffer, "Referenced data badly set");
76 fail_unless(bufref.len == 13, "Data size badly set");
77 fail_unless(bufref.dtor == test_free, "Destructor badly set");
83 fail_unless((char *) Curl_bufref_ptr(&bufref) == buffer,
90 fail_unless(Curl_bufref_len(&bufref) == 13, "Wrong data size returned");
96 result = Curl_bufref_memdup(&bufref, "1661", 3);
99 fail_unless((char *) bufref.ptr != buffer, "Returned pointer not set");
100 buffer = (char *) Curl_bufref_ptr(&bufref);
102 fail_unless(bufref.len == 3, "Wrong data size stored");
110 Curl_bufref_free(&bufref);
112 fail_unless(!bufref.ptr, "Initial reference must be NULL");
113 fail_unless(!bufref.len, "Initial length must be NULL");
114 fail_unless(!bufref.dtor, "Destructor must be NULL");