Searched refs:buf (Results 1 - 25 of 5584) sorted by relevance

1234567891011>>

/external/clang/test/Analysis/
H A Dundef-buffers.c7 char buf[2]; local
8 buf[0] = 'a';
9 return buf[1]; // expected-warning{{Undefined}}
13 char buf[2]; local
14 buf[1] = 'a';
15 return buf[0]; // expected-warning{{Undefined}}
20 char buf[2]; local
22 buf[0] = 'a';
24 return buf[1]; // expected-warning{{Undefined}}
26 return buf[
30 char *buf = malloc(2); local
38 char *buf = malloc(2); local
[all...]
H A DPR7218.c3 char buf[2]; local
4 buf[0] = a;
5 return buf[1]; // expected-warning {{Undefined or garbage value returned to caller}}
H A Dout-of-bounds.c7 int buf[100]; local
8 buf[100] = 1; // expected-warning{{Out of bound memory access}}
12 int buf[100]; local
13 buf[99] = 1; // no-warning
36 int buf[100]; local
37 int *p = buf;
42 int buf[100]; local
43 int *p = buf;
52 int buf[100]; local
53 int *p = buf;
59 int buf[100]; local
66 int buf[100]; local
73 int buf[100]; local
83 int buf[100]; local
92 int buf[100]; local
102 int buf[100]; local
113 int buf[100][100]; local
122 int buf[100][100]; local
127 int buf[100][100]; local
135 int buf[100]; local
144 int buf[100]; local
153 int *buf = get_symbolic(); local
[all...]
/external/valgrind/main/none/tests/x86/
H A Dcpuid_c.c5 extern void get_cpuid0 ( unsigned int* buf );
6 extern void get_cpuid1 ( unsigned int* buf );
8 unsigned int buf[4]; variable
12 get_cpuid0(&buf[0]);
14 buf[0], buf[1], buf[2], buf[3] );
16 get_cpuid1(&buf[0]);
18 buf[
[all...]
/external/chromium_org/native_client_sdk/src/libraries/nacl_io/syscalls/
H A Dgetwd.c8 char* getwd(char* buf) { argument
9 return ki_getwd(buf);
H A Dgetcwd.c8 char* getcwd(char* buf, size_t size) { argument
9 return ki_getcwd(buf, size);
H A Dgetdents.c8 int getdents(int fd, void* buf, unsigned int count) { argument
9 return ki_getdents(fd, buf, count);
/external/dropbear/libtomcrypt/src/misc/
H A Dburn_stack.c24 unsigned char buf[32]; local
25 zeromem(buf, sizeof(buf));
26 if (len > (unsigned long)sizeof(buf))
27 burn_stack(len - sizeof(buf));
/external/chromium_org/third_party/mesa/src/src/gallium/auxiliary/util/
H A Du_dynarray.h47 util_dynarray_init(struct util_dynarray *buf) argument
49 memset(buf, 0, sizeof(*buf));
53 util_dynarray_fini(struct util_dynarray *buf) argument
55 if(buf->data)
57 FREE(buf->data);
58 util_dynarray_init(buf);
64 util_dynarray_resize(struct util_dynarray *buf, unsigned newsize) argument
67 if(newsize > buf->capacity)
69 unsigned newcap = buf
82 util_dynarray_grow(struct util_dynarray *buf, int diff) argument
88 util_dynarray_trim(struct util_dynarray *buf) argument
[all...]
/external/mesa3d/src/gallium/auxiliary/util/
H A Du_dynarray.h47 util_dynarray_init(struct util_dynarray *buf) argument
49 memset(buf, 0, sizeof(*buf));
53 util_dynarray_fini(struct util_dynarray *buf) argument
55 if(buf->data)
57 FREE(buf->data);
58 util_dynarray_init(buf);
64 util_dynarray_resize(struct util_dynarray *buf, unsigned newsize) argument
67 if(newsize > buf->capacity)
69 unsigned newcap = buf
82 util_dynarray_grow(struct util_dynarray *buf, int diff) argument
88 util_dynarray_trim(struct util_dynarray *buf) argument
[all...]
/external/compiler-rt/lib/msan/lit_tests/Linux/
H A Dsyscalls.cc17 char buf[1000]; local
19 memset(buf, 0, sizeof(buf));
20 __msan_unpoison(buf, sizeof(buf));
21 __sanitizer_syscall_pre_recvmsg(0, buf, 0);
22 __sanitizer_syscall_pre_rt_sigpending(buf, kTen);
23 __sanitizer_syscall_pre_getdents(0, buf, kTen);
24 __sanitizer_syscall_pre_getdents64(0, buf, kTen);
26 __msan_unpoison(buf, sizeo
[all...]
/external/chromium_org/third_party/libjingle/source/talk/base/
H A Dbyteorder_unittest.cc37 uint8 buf[8] = { 0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u }; local
38 Set8(buf, 0, 0xfb);
39 Set8(buf, 1, 0x12);
40 EXPECT_EQ(0xfb, buf[0]);
41 EXPECT_EQ(0x12, buf[1]);
42 SetBE16(buf, 0x1234);
43 EXPECT_EQ(0x12, buf[0]);
44 EXPECT_EQ(0x34, buf[1]);
45 SetLE16(buf, 0x1234);
46 EXPECT_EQ(0x34, buf[
80 uint8 buf[8]; local
[all...]
/external/dropbear/libtomcrypt/notes/etc/
H A Dwhirltest.c5 char buf[4096]; local
8 while (fgets(buf, sizeof(buf)-2, stdin) != NULL) {
10 printf("0x%c%c, ", buf[x], buf[x+1]);
/external/compiler-rt/lib/sanitizer_common/tests/
H A Dsanitizer_printf_test.cc23 char buf[1024]; local
24 uptr len = internal_snprintf(buf, sizeof(buf),
30 EXPECT_EQ(len, strlen(buf));
34 "0x00000123e_string_r", buf);
37 "0x000000000123e_string_r", buf);
42 char buf[] = "123456789"; local
43 uptr len = internal_snprintf(buf, 4, "%s", "abcdef"); // NOLINT
45 EXPECT_STREQ("abc", buf);
46 EXPECT_EQ(buf[
56 char buf[] = "123456789"; local
69 char buf[] = "123456789"; local
88 char buf[] = "123456789"; local
108 char buf[1024]; local
[all...]
/external/chromium_org/content/browser/loader/
H A Dresource_buffer_unittest.cc11 scoped_refptr<ResourceBuffer> buf = new ResourceBuffer(); local
12 EXPECT_TRUE(buf->Initialize(100, 5, 10));
13 EXPECT_TRUE(buf->CanAllocate());
18 char* ptr = buf->Allocate(&size);
21 EXPECT_TRUE(buf->CanAllocate());
23 EXPECT_EQ(0, buf->GetLastAllocationOffset());
25 buf->ShrinkLastAllocation(2); // Less than our min allocation size.
26 EXPECT_EQ(0, buf->GetLastAllocationOffset());
27 EXPECT_TRUE(buf->CanAllocate());
33 char* ptr = buf
48 scoped_refptr<ResourceBuffer> buf = new ResourceBuffer(); local
64 scoped_refptr<ResourceBuffer> buf = new ResourceBuffer(); local
85 scoped_refptr<ResourceBuffer> buf = new ResourceBuffer(); local
119 scoped_refptr<ResourceBuffer> buf = new ResourceBuffer(); local
[all...]
/external/qemu/
H A Dvarint.c42 char *varint_encode(uint64_t value, char *buf) { argument
44 *buf++ = value;
46 *buf++ = (2 << 6) | (value >> 8);
47 *buf++ = value & 0xff;
49 *buf++ = (6 << 5) | (value >> 16);
50 *buf++ = (value >> 8) & 0xff;
51 *buf++ = value & 0xff;
53 *buf++ = (0xe << 4) | (value >> 24);
54 *buf++ = (value >> 16) & 0xff;
55 *buf
95 varint_encode_signed(int64_t value, char *buf) argument
[all...]
H A Dvarint.h14 extern char *varint_encode(uint64_t value, char *buf);
15 extern char *varint_encode_signed(int64_t value, char *buf);
/external/chromium_org/third_party/openssl/openssl/crypto/
H A Dcversion.c72 static char buf[sizeof(DATE)+11]; local
74 BIO_snprintf(buf,sizeof buf,"built on: %s",DATE);
75 return(buf);
83 static char buf[sizeof(CFLAGS)+11]; local
85 BIO_snprintf(buf,sizeof buf,"compiler: %s",CFLAGS);
86 return(buf);
94 static char buf[sizeof(PLATFORM)+11]; local
96 BIO_snprintf(buf,sizeo
[all...]
/external/openssl/crypto/
H A Dcversion.c72 static char buf[sizeof(DATE)+11]; local
74 BIO_snprintf(buf,sizeof buf,"built on: %s",DATE);
75 return(buf);
83 static char buf[sizeof(CFLAGS)+11]; local
85 BIO_snprintf(buf,sizeof buf,"compiler: %s",CFLAGS);
86 return(buf);
94 static char buf[sizeof(PLATFORM)+11]; local
96 BIO_snprintf(buf,sizeo
[all...]
/external/dropbear/
H A Dbuffer.c43 buffer* buf; local
46 dropbear_exit("buf->size too big");
49 buf = (buffer*)m_malloc(sizeof(buffer));
52 buf->data = (unsigned char*)m_malloc(size);
54 buf->data = NULL;
57 buf->size = size;
58 buf->pos = 0;
59 buf->len = 0;
61 return buf;
66 void buf_free(buffer* buf) { argument
73 buf_burn(buffer* buf) argument
81 buf_resize(buffer *buf, unsigned int newsize) argument
96 buf_newcopy(buffer* buf) argument
107 buf_setlen(buffer* buf, unsigned int len) argument
115 buf_incrlen(buffer* buf, unsigned int incr) argument
122 buf_setpos(buffer* buf, unsigned int pos) argument
131 buf_incrwritepos(buffer* buf, unsigned int incr) argument
143 buf_incrpos(buffer* buf, int incr) argument
153 buf_getbyte(buffer* buf) argument
164 buf_getbool(buffer* buf) argument
174 buf_putbyte(buffer* buf, unsigned char val) argument
185 buf_getptr(buffer* buf, unsigned int len) argument
195 buf_getwriteptr(buffer* buf, unsigned int len) argument
206 buf_getstring(buffer* buf, unsigned int *retlen) argument
228 buf_eatstring(buffer *buf) argument
234 buf_getint(buffer* buf) argument
243 buf_putint(buffer* buf, int unsigned val) argument
251 buf_putstring(buffer* buf, const unsigned char* str, unsigned int len) argument
260 buf_putbytes(buffer *buf, const unsigned char *bytes, unsigned int len) argument
268 buf_putmpint(buffer* buf, mp_int * mp) argument
313 buf_getmpint(buffer* buf, mp_int* mp) argument
[all...]
H A Dbuffer.h31 struct buf { struct
40 typedef struct buf buffer;
43 void buf_resize(buffer *buf, unsigned int newsize);
44 void buf_free(buffer* buf);
45 void buf_burn(buffer* buf);
46 buffer* buf_newcopy(buffer* buf);
47 void buf_setlen(buffer* buf, unsigned int len);
48 void buf_incrlen(buffer* buf, unsigned int incr);
49 void buf_setpos(buffer* buf, unsigned int pos);
50 void buf_incrpos(buffer* buf, in
[all...]
/external/wpa_supplicant_8/hostapd/src/utils/
H A Dwpabuf.h12 /* wpabuf::buf is a pointer to external data */
23 u8 *buf; /* pointer to the head of the buffer */ member in struct:wpabuf
29 int wpabuf_resize(struct wpabuf **buf, size_t add_len);
34 void wpabuf_free(struct wpabuf *buf);
35 void * wpabuf_put(struct wpabuf *buf, size_t len);
37 struct wpabuf * wpabuf_zeropad(struct wpabuf *buf, size_t len);
38 void wpabuf_printf(struct wpabuf *buf, char *fmt, ...) PRINTF_FORMAT(2, 3);
43 * @buf: wpabuf buffer
46 static inline size_t wpabuf_size(const struct wpabuf *buf) argument
48 return buf
56 wpabuf_len(const struct wpabuf *buf) argument
66 wpabuf_tailroom(const struct wpabuf *buf) argument
76 wpabuf_head(const struct wpabuf *buf) argument
81 wpabuf_head_u8(const struct wpabuf *buf) argument
91 wpabuf_mhead(struct wpabuf *buf) argument
96 wpabuf_mhead_u8(struct wpabuf *buf) argument
101 wpabuf_put_u8(struct wpabuf *buf, u8 data) argument
107 wpabuf_put_le16(struct wpabuf *buf, u16 data) argument
113 wpabuf_put_le32(struct wpabuf *buf, u32 data) argument
119 wpabuf_put_be16(struct wpabuf *buf, u16 data) argument
125 wpabuf_put_be24(struct wpabuf *buf, u32 data) argument
131 wpabuf_put_be32(struct wpabuf *buf, u32 data) argument
137 wpabuf_put_data(struct wpabuf *buf, const void *data, size_t len) argument
150 wpabuf_set(struct wpabuf *buf, const void *data, size_t len) argument
[all...]
H A Dwpabuf.c22 static struct wpabuf_trace * wpabuf_get_trace(const struct wpabuf *buf) argument
25 ((const u8 *) buf - sizeof(struct wpabuf_trace));
30 static void wpabuf_overflow(const struct wpabuf *buf, size_t len) argument
33 struct wpabuf_trace *trace = wpabuf_get_trace(buf);
40 buf, (unsigned long) buf->size, (unsigned long) buf->used,
49 struct wpabuf *buf = *_buf; local
54 if (buf == NULL) {
60 trace = wpabuf_get_trace(buf);
118 struct wpabuf *buf; local
140 struct wpabuf *buf; local
162 struct wpabuf *buf = wpabuf_alloc(len); local
171 struct wpabuf *buf = wpabuf_alloc(wpabuf_len(src)); local
182 wpabuf_free(struct wpabuf *buf) argument
208 wpabuf_put(struct wpabuf *buf, size_t len) argument
268 wpabuf_zeropad(struct wpabuf *buf, size_t len) argument
291 wpabuf_printf(struct wpabuf *buf, char *fmt, ...) argument
[all...]
/external/wpa_supplicant_8/src/utils/
H A Dwpabuf.h12 /* wpabuf::buf is a pointer to external data */
23 u8 *buf; /* pointer to the head of the buffer */ member in struct:wpabuf
29 int wpabuf_resize(struct wpabuf **buf, size_t add_len);
34 void wpabuf_free(struct wpabuf *buf);
35 void * wpabuf_put(struct wpabuf *buf, size_t len);
37 struct wpabuf * wpabuf_zeropad(struct wpabuf *buf, size_t len);
38 void wpabuf_printf(struct wpabuf *buf, char *fmt, ...) PRINTF_FORMAT(2, 3);
43 * @buf: wpabuf buffer
46 static inline size_t wpabuf_size(const struct wpabuf *buf) argument
48 return buf
56 wpabuf_len(const struct wpabuf *buf) argument
66 wpabuf_tailroom(const struct wpabuf *buf) argument
76 wpabuf_head(const struct wpabuf *buf) argument
81 wpabuf_head_u8(const struct wpabuf *buf) argument
91 wpabuf_mhead(struct wpabuf *buf) argument
96 wpabuf_mhead_u8(struct wpabuf *buf) argument
101 wpabuf_put_u8(struct wpabuf *buf, u8 data) argument
107 wpabuf_put_le16(struct wpabuf *buf, u16 data) argument
113 wpabuf_put_le32(struct wpabuf *buf, u32 data) argument
119 wpabuf_put_be16(struct wpabuf *buf, u16 data) argument
125 wpabuf_put_be24(struct wpabuf *buf, u32 data) argument
131 wpabuf_put_be32(struct wpabuf *buf, u32 data) argument
137 wpabuf_put_data(struct wpabuf *buf, const void *data, size_t len) argument
150 wpabuf_set(struct wpabuf *buf, const void *data, size_t len) argument
[all...]
/external/wpa_supplicant_8/wpa_supplicant/src/utils/
H A Dwpabuf.h12 /* wpabuf::buf is a pointer to external data */
23 u8 *buf; /* pointer to the head of the buffer */ member in struct:wpabuf
29 int wpabuf_resize(struct wpabuf **buf, size_t add_len);
34 void wpabuf_free(struct wpabuf *buf);
35 void * wpabuf_put(struct wpabuf *buf, size_t len);
37 struct wpabuf * wpabuf_zeropad(struct wpabuf *buf, size_t len);
38 void wpabuf_printf(struct wpabuf *buf, char *fmt, ...) PRINTF_FORMAT(2, 3);
43 * @buf: wpabuf buffer
46 static inline size_t wpabuf_size(const struct wpabuf *buf) argument
48 return buf
56 wpabuf_len(const struct wpabuf *buf) argument
66 wpabuf_tailroom(const struct wpabuf *buf) argument
76 wpabuf_head(const struct wpabuf *buf) argument
81 wpabuf_head_u8(const struct wpabuf *buf) argument
91 wpabuf_mhead(struct wpabuf *buf) argument
96 wpabuf_mhead_u8(struct wpabuf *buf) argument
101 wpabuf_put_u8(struct wpabuf *buf, u8 data) argument
107 wpabuf_put_le16(struct wpabuf *buf, u16 data) argument
113 wpabuf_put_le32(struct wpabuf *buf, u32 data) argument
119 wpabuf_put_be16(struct wpabuf *buf, u16 data) argument
125 wpabuf_put_be24(struct wpabuf *buf, u32 data) argument
131 wpabuf_put_be32(struct wpabuf *buf, u32 data) argument
137 wpabuf_put_data(struct wpabuf *buf, const void *data, size_t len) argument
150 wpabuf_set(struct wpabuf *buf, const void *data, size_t len) argument
[all...]

Completed in 626 milliseconds

1234567891011>>