Searched refs:buf (Results 1 - 25 of 3827) 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/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/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/apache-harmony/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/
H A DFloatBufferTest.java37 protected FloatBuffer buf; field in class:FloatBufferTest
40 buf = FloatBuffer.allocate(BUFFER_LENGTH);
41 loadTestData1(buf);
42 baseBuf = buf;
46 buf = null;
51 float array[] = buf.array();
52 assertContentEquals(buf, array, buf.arrayOffset(), buf.capacity());
54 loadTestData1(array, buf
638 loadTestData1(FloatBuffer buf) argument
645 loadTestData2(FloatBuffer buf) argument
652 assertContentEquals(FloatBuffer buf, float array[], int offset, int length) argument
659 assertContentEquals(FloatBuffer buf, FloatBuffer other) argument
666 assertContentLikeTestData1(FloatBuffer buf, int startIndex, float startValue, int length) argument
[all...]
H A DLongBufferTest.java37 protected LongBuffer buf; field in class:LongBufferTest
40 buf = LongBuffer.allocate(BUFFER_LENGTH);
41 loadTestData1(buf);
42 baseBuf = buf;
46 buf = null;
51 long array[] = buf.array();
52 assertContentEquals(buf, array, buf.arrayOffset(), buf.capacity());
54 loadTestData1(array, buf
621 loadTestData1(LongBuffer buf) argument
628 loadTestData2(LongBuffer buf) argument
635 assertContentEquals(LongBuffer buf, long array[], int offset, int length) argument
642 assertContentEquals(LongBuffer buf, LongBuffer other) argument
649 assertContentLikeTestData1(LongBuffer buf, int startIndex, long startValue, int length) argument
[all...]
H A DIntBufferTest.java37 protected IntBuffer buf; field in class:IntBufferTest
40 buf = IntBuffer.allocate(BUFFER_LENGTH);
41 loadTestData1(buf);
42 baseBuf = buf;
46 buf = null;
51 int array[] = buf.array();
52 assertContentEquals(buf, array, buf.arrayOffset(), buf.capacity());
54 loadTestData1(array, buf
614 loadTestData1(IntBuffer buf) argument
621 loadTestData2(IntBuffer buf) argument
628 assertContentEquals(IntBuffer buf, int array[], int offset, int length) argument
635 assertContentEquals(IntBuffer buf, IntBuffer other) argument
642 assertContentLikeTestData1(IntBuffer buf, int startIndex, int startValue, int length) argument
[all...]
H A DShortBufferTest.java36 protected ShortBuffer buf; field in class:ShortBufferTest
39 buf = ShortBuffer.allocate(BUFFER_LENGTH);
40 loadTestData1(buf);
41 baseBuf = buf;
45 buf = null;
50 short array[] = buf.array();
51 assertContentEquals(buf, array, buf.arrayOffset(), buf.capacity());
53 loadTestData1(array, buf
601 loadTestData1(ShortBuffer buf) argument
608 loadTestData2(ShortBuffer buf) argument
615 assertContentEquals(ShortBuffer buf, short array[], int offset, int length) argument
622 assertContentEquals(ShortBuffer buf, ShortBuffer other) argument
629 assertContentLikeTestData1(ShortBuffer buf, int startIndex, short startValue, int length) argument
[all...]
H A DDoubleBufferTest.java36 protected DoubleBuffer buf; field in class:DoubleBufferTest
39 buf = DoubleBuffer.allocate(BUFFER_LENGTH);
40 loadTestData1(buf);
41 baseBuf = buf;
45 buf = null;
75 double array[] = buf.array();
76 assertContentEquals(buf, array, buf.arrayOffset(), buf.capacity());
78 loadTestData1(array, buf
628 loadTestData1(DoubleBuffer buf) argument
635 loadTestData2(DoubleBuffer buf) argument
642 assertContentEquals(DoubleBuffer buf, double array[], int offset, int length) argument
649 assertContentEquals(DoubleBuffer buf, DoubleBuffer other) argument
656 assertContentLikeTestData1(DoubleBuffer buf, int startIndex, double startValue, int length) argument
[all...]
H A DCharBufferTest.java37 protected CharBuffer buf; field in class:CharBufferTest
44 buf = CharBuffer.wrap(charscopy);
45 baseBuf = buf;
49 buf = null;
54 char array[] = buf.array();
55 assertContentEquals(buf, array, buf.arrayOffset(), buf.capacity());
57 loadTestData1(array, buf.arrayOffset(), buf
820 loadTestData1(CharBuffer buf) argument
827 loadTestData2(CharBuffer buf) argument
834 assertContentEquals(CharBuffer buf, char array[], int offset, int length) argument
841 assertContentEquals(CharBuffer buf, CharBuffer other) argument
848 assertContentLikeTestData1(CharBuffer buf, int startIndex, char startValue, int length) argument
[all...]
/external/compiler-rt/lib/tsan/unit_tests/
H A Dtsan_printf_test.cc22 char buf[1024]; local
23 uptr len = internal_snprintf(buf, sizeof(buf),
29 EXPECT_EQ(len, strlen(buf));
30 EXPECT_EQ(0, strcmp(buf, "a-1b-2c4294967292e5fahbq"
35 char buf[] = "123456789"; local
36 uptr len = internal_snprintf(buf, 4, "%s", "abcdef"); // NOLINT
38 EXPECT_EQ(0, strcmp(buf, "abc"));
39 EXPECT_EQ(buf[3], 0);
40 EXPECT_EQ(buf[
49 char buf[] = "123456789"; local
62 char buf[] = "123456789"; local
75 char buf[] = "123456789"; local
89 char buf[1024]; 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/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_6/wpa_supplicant/src/utils/
H A Dwpabuf.c20 static void wpabuf_overflow(const struct wpabuf *buf, size_t len) argument
23 buf, (unsigned long) buf->size, (unsigned long) buf->used,
31 struct wpabuf *buf = *_buf; local
32 if (buf == NULL) {
36 if (buf->used + add_len > buf->size) {
38 if (buf->ext_data) {
39 nbuf = os_realloc(buf
68 struct wpabuf *buf = os_zalloc(sizeof(struct wpabuf) + len); local
78 struct wpabuf *buf = os_zalloc(sizeof(struct wpabuf)); local
92 struct wpabuf *buf = wpabuf_alloc(len); local
101 struct wpabuf *buf = wpabuf_alloc(wpabuf_len(src)); local
112 wpabuf_free(struct wpabuf *buf) argument
121 wpabuf_put(struct wpabuf *buf, size_t len) argument
181 wpabuf_zeropad(struct wpabuf *buf, size_t len) argument
204 wpabuf_printf(struct wpabuf *buf, char *fmt, ...) argument
[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...]
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/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...]
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...]

Completed in 350 milliseconds

1234567891011>>