/external/openssl/crypto/rand/ |
rand_win.c | 203 osverinfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFO) ; 213 /* The CryptoAPI returns sizeof(buf) bytes of randomness */ 217 if (CryptGenRandom(hProvider, sizeof(buf), buf)) 218 RAND_add(buf, sizeof(buf), sizeof(buf)); 267 RAND_add(outbuf, sizeof(STAT_WORKSTATION_0), 45); 272 RAND_add(outbuf, sizeof(STAT_SERVER_0), 17); 318 RAND_add(&length, sizeof(length), 0); 353 /* The CryptoAPI returns sizeof(buf) bytes of randomness */ 357 if (gen(hProvider, sizeof(buf), buf) != 0 [all...] |
/external/tcpdump/ |
print-icmp.c | 104 #define ICMP_EXTD_MINLEN (156 - sizeof (struct ip)) /* draft-bonica-internet-icmp-08 */ 105 #define ICMP_TSLEN (8 + 3 * sizeof (u_int32_t)) /* timestamp */ 107 #define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) /* min */ 329 snprintf(buf, sizeof(buf), "%02u:%02u:%02u.%03u",hrs,min,sec,msec); 361 (void)snprintf(buf, sizeof(buf), "echo %s, id %u, seq %u", 374 (void)snprintf(buf, sizeof(buf), 390 (void)snprintf(buf, sizeof(buf), 397 (void)snprintf(buf, sizeof(buf), 404 (void)snprintf(buf, sizeof(buf), 418 (void)snprintf(buf, sizeof(buf) [all...] |
/device/samsung/crespo/alsa-utils/alsactl/ |
init_parse.c | 160 pair = malloc(sizeof(struct pair)); 186 res = calloc(1, sizeof(struct space)); 287 strlcat(res, ",", sizeof(res)); 288 strlcat(res, snd_ctl_elem_value_get_boolean(space->ctl_value, idx) ? "on" : "off", sizeof(res)); 294 strlcat(res, ",", sizeof(res)); 295 snprintf(tmp, sizeof(tmp), "%li", snd_ctl_elem_value_get_integer(space->ctl_value, idx)); 296 strlcat(res, tmp, sizeof(res)); 302 strlcat(res, ",", sizeof(res)); 303 snprintf(tmp, sizeof(tmp), "%lli", snd_ctl_elem_value_get_integer64(space->ctl_value, idx)); 304 strlcat(res, tmp, sizeof(res)) [all...] |
/external/elfutils/libebl/ |
eblwstrtab.c | 81 ps = sysconf (_SC_PAGESIZE) - 2 * sizeof (void *); 82 assert (sizeof (struct memoryblock) < ps); 85 ret = (struct Ebl_WStrtab *) calloc (1, sizeof (struct Ebl_WStrtab)); 149 if (st->left < align + sizeof (struct Ebl_WStrent) + len * sizeof (wchar_t)) 152 sizeof (struct Ebl_WStrent) + len * sizeof (wchar_t))) 169 st->backp += align + sizeof (struct Ebl_WStrent) + len * sizeof (wchar_t); 170 st->left -= align + sizeof (struct Ebl_WStrent) + len * sizeof (wchar_t) [all...] |
/external/fsck_msdos/ |
boot.c | 60 if (read(dosfs, block, sizeof block) < sizeof block) { 70 memset(boot, 0, sizeof *boot); 111 || read(dosfs, fsinfo, sizeof fsinfo) 112 != sizeof fsinfo) { 138 || write(dosfs, fsinfo, sizeof fsinfo) 139 != sizeof fsinfo) { 158 || read(dosfs, backup, sizeof backup) != sizeof backup) { 179 snprintf(tmp2, sizeof(tmp2), "%.2x ", block[11 + i]) [all...] |
/external/giflib/ |
gifalloc.c | 60 Object = (ColorMapObject *)malloc(sizeof(ColorMapObject)); 65 Object->Colors = (GifColorType *)calloc(ColorCount, sizeof(GifColorType)); 75 (char *)ColorMap, ColorCount * sizeof(GifColorType)); 172 sizeof(GifColorType)) == 0) 206 sizeof(GifColorType) * RoundUpTo); 258 New->ExtensionBlocks=(ExtensionBlock *)malloc(sizeof(ExtensionBlock)); 261 sizeof(ExtensionBlock) * 348 GifFile->SavedImages = (SavedImage *)malloc(sizeof(SavedImage)); 351 sizeof(SavedImage) * (GifFile->ImageCount + 1)); 357 memset((char *)sp, '\0', sizeof(SavedImage)) [all...] |
/external/iproute2/tc/ |
q_hfsc.c | 74 memset(&qopt, 0, sizeof(qopt)); 98 addattr_l(n, 1024, TCA_OPTIONS, &qopt, sizeof(qopt)); 109 if (RTA_PAYLOAD(opt) < sizeof(*qopt)) 126 if (RTA_PAYLOAD(xstats) < sizeof(*st)) 149 memset(&rsc, 0, sizeof(rsc)); 150 memset(&fsc, 0, sizeof(fsc)); 151 memset(&usc, 0, sizeof(usc)); 175 memcpy(&fsc, &rsc, sizeof(fsc)); 212 addattr_l(n, 1024, TCA_HFSC_RSC, &rsc, sizeof(rsc)); 214 addattr_l(n, 1024, TCA_HFSC_FSC, &fsc, sizeof(fsc)) [all...] |
/external/libpcap/ |
pcap-nit.c | 113 snprintf(p->errbuf, sizeof(p->errbuf), "pcap_read: %s", 150 cp = bp + sizeof(*nh); 167 snprintf(p->errbuf, sizeof(p->errbuf), 172 bp += ((sizeof(struct nit_hdr) + nh->nh_datalen + 173 sizeof(int) - 1) & ~(sizeof(int) - 1)); 201 memset(&sa, 0, sizeof(sa)); 202 strncpy(sa.sa_data, device, sizeof(sa.sa_data)); 203 ret = sendto(p->fd, buf, size, 0, &sa, sizeof(sa)); 217 memset(&nioc, 0, sizeof(nioc)) [all...] |
/external/wpa_supplicant/ |
main_winsvc.c | 83 os_memset(&iface, 0, sizeof(iface)); 86 buflen = sizeof(ctrl_interface); 97 buflen = sizeof(adapter); 108 buflen = sizeof(config); 112 config[sizeof(config) - 1] = '\0'; 140 os_memset(¶ms, 0, sizeof(params)); 150 buflen = sizeof(val); 153 if (ret == ERROR_SUCCESS && buflen == sizeof(val)) { 157 buflen = sizeof(val); 160 if (ret == ERROR_SUCCESS && buflen == sizeof(val)) [all...] |
/bionic/libc/kernel/common/linux/ |
rtnetlink.h | 137 #define RTA_OK(rta,len) ((len) >= (int)sizeof(struct rtattr) && (rta)->rta_len >= sizeof(struct rtattr) && (rta)->rta_len <= (len)) 139 #define RTA_LENGTH(len) (RTA_ALIGN(sizeof(struct rtattr)) + (len)) 243 #define RTM_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct rtmsg)))) 244 #define RTM_PAYLOAD(n) NLMSG_PAYLOAD(n,sizeof(struct rtmsg)) 260 #define RTNH_OK(rtnh,len) ((rtnh)->rtnh_len >= sizeof(struct rtnexthop) && ((int)(rtnh)->rtnh_len) <= (len)) 262 #define RTNH_LENGTH(len) (RTNH_ALIGN(sizeof(struct rtnexthop)) + (len)) 412 #define TCA_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct tcmsg)))) 413 #define TCA_PAYLOAD(n) NLMSG_PAYLOAD(n,sizeof(struct tcmsg)) 512 #define TA_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct tcamsg))) [all...] |
/external/chromium/base/ |
debug_util_win.cc | 29 DWORD buffer_size = *len * sizeof(wchar_t); 48 memset(output, 0, output_len*sizeof(wchar_t)); 120 (sizeof(SYMBOL_INFO) + 121 kMaxNameLength * sizeof(wchar_t) + 122 sizeof(ULONG64) - 1) / 123 sizeof(ULONG64)]; 124 memset(buffer, 0, sizeof(buffer)); 129 symbol->SizeOfStruct = sizeof(SYMBOL_INFO); 137 line.SizeOfStruct = sizeof(IMAGEHLP_LINE64); 200 startup_info.cb = sizeof(startup_info) [all...] |
/external/dnsmasq/contrib/wrt/ |
dhcp_release.c | 197 req.nlh.nlmsg_len = sizeof(req); 204 if (sendto(fd, (void *)&req, sizeof(req), 0, 205 (struct sockaddr *)&addr, sizeof(addr)) == -1) 226 unsigned int len1 = h->nlmsg_len - NLMSG_LENGTH(sizeof(*ifa)); 278 if (setsockopt(fd, SOL_SOCKET, SO_BINDTODEVICE, &ifr, sizeof(ifr)) == -1) 288 memset(&packet, 0, sizeof(packet)); 305 *(p++) = sizeof(server); 306 memcpy(p, &server, sizeof(server)); 307 p += sizeof(server); 323 if (sendto(fd, &packet, sizeof(packet), 0, [all...] |
/external/elfutils/tests/ |
asm-tst9.c | 30 #define ninput (sizeof (input) / sizeof (input[0])) 46 .e_ehsize = sizeof (Elf32_Ehdr), 47 .e_shentsize = sizeof (Elf32_Shdr), 182 if (memcmp (ehdr, &expected_ehdr, sizeof (GElf_Ehdr)) != 0) 240 if ((cnt == 1 && shdr->sh_offset != ((sizeof (Elf32_Ehdr) + 15) & ~15)) 242 && shdr->sh_offset != (((sizeof (Elf32_Ehdr) + 15) & ~15) 243 + sizeof (expecteddata)))) 249 if ((cnt == 1 && shdr->sh_size != sizeof (expecteddata)) 292 if (data->d_size != sizeof (expecteddata) [all...] |
/external/iproute2/ip/ |
ipxfrm.c | 45 int rest = sizeof(buf) - 1 - strlen(buf); \ 51 buf[sizeof(buf) - 1] = '\0'; \ 198 const int sn = sizeof(mask) * 8 - 1; 288 memset(abuf, '\0', sizeof(abuf)); 289 fprintf(fp, "src %s ", rt_addr_n2a(family, sizeof(*saddr), 290 saddr, abuf, sizeof(abuf))); 291 memset(abuf, '\0', sizeof(abuf)); 292 fprintf(fp, "dst %s", rt_addr_n2a(family, sizeof(id->daddr), 293 &id->daddr, abuf, sizeof(abuf))); 378 strftime(str, sizeof(str), "%Y-%m-%d %T", tp) [all...] |
xfrm_state.c | 128 strncpy(alg->alg_name, name, sizeof(alg->alg_name)); 246 memset(&req, 0, sizeof(req)); 247 memset(&replay, 0, sizeof(replay)); 249 req.n.nlmsg_len = NLMSG_LENGTH(sizeof(req.xsinfo)); 305 memcpy(&encap.encap_oa, &oa.data, sizeof(encap.encap_oa)); 306 addattr_l(&req.n, sizeof(req.buf), XFRMA_ENCAP, 307 (void *)&encap, sizeof(encap)); 321 if (coa.bytelen > sizeof(xcoa)) 324 memset(&xcoa, 0, sizeof(xcoa)); 327 addattr_l(&req.n, sizeof(req.buf), XFRMA_COADDR [all...] |
/external/qemu/block/ |
cow.c | 58 if (buf_size >= sizeof(struct cow_header_v2) && 81 if (read(fd, &cow_header, sizeof(cow_header)) != sizeof(cow_header)) { 94 pstrcpy(bs->backing_file, sizeof(bs->backing_file), 98 s->cow_bitmap_size = ((bs->total_sectors + 7) >> 3) + sizeof(cow_header); 105 s->cow_bitmap = s->cow_bitmap_addr + sizeof(cow_header); 227 memset(&cow_header, 0, sizeof(cow_header)); 246 pstrcpy(cow_header.backing_file, sizeof(cow_header.backing_file), 251 write(cow_fd, &cow_header, sizeof(cow_header)); 253 ftruncate(cow_fd, sizeof(cow_header) + ((image_sectors + 7) >> 3)) [all...] |
/external/qemu/distrib/sdl-1.2.12/src/video/windx5/ |
SDL_dx5yuv.c | 58 SDL_memset(&ddsd, 0, sizeof(ddsd)); 59 ddsd.dwSize = sizeof(ddsd); 68 ddsd.ddpfPixelFormat.dwSize = sizeof(ddsd.ddpfPixelFormat); 87 SDL_memset(&ddsd, 0, sizeof(ddsd)); 88 ddsd.dwSize = sizeof(ddsd); 135 codes = SDL_malloc(numcodes*sizeof(*codes)); 149 overlay = (SDL_Overlay *)SDL_malloc(sizeof *overlay); 154 SDL_memset(overlay, 0, (sizeof *overlay)); 165 hwdata = (struct private_yuvhwdata *)SDL_malloc(sizeof *hwdata); 203 SDL_memset(&ddsd, 0, sizeof(ddsd)) [all...] |
/external/quake/quake/src/QW/server/ |
model.c | 52 memset (mod_novis, 0xff, sizeof(mod_novis)); 219 buf = (unsigned *)COM_LoadStackFile (mod->name, stackbuf, sizeof(stackbuf)); 298 loadmodel->textures = Hunk_AllocName (m->nummiptex * sizeof(*loadmodel->textures) , loadname); 314 tx = Hunk_AllocName (sizeof(texture_t) +pixels, loadname ); 317 memcpy (tx->name, mt->name, sizeof(tx->name)); 321 tx->offsets[j] = mt->offsets[j] + sizeof(texture_t) - sizeof(miptex_t); 338 memset (anims, 0, sizeof(anims)); 339 memset (altanims, 0, sizeof(altanims)); 483 if (l->filelen % sizeof(*in) [all...] |
/external/skia/include/core/ |
SkTDArray.h | 40 fArray = (T*)sk_malloc_throw(count * sizeof(T)); 44 memcpy(fArray, src, sizeof(T) * count); 67 memcpy(fArray, src.fArray, sizeof(T) * src.fCount); 77 !memcmp(a.fArray, b.fArray, a.fCount * sizeof(T))); 146 memmove(fArray + 1, fArray, (fCount - 1) * sizeof(T)); 161 memcpy(fArray + oldCount, src, sizeof(T) * count); 182 memmove(dst + count, dst, sizeof(T) * (oldCount - index)); 184 memcpy(dst, src, sizeof(T) * count); 192 memmove(fArray + index, fArray + index + count, sizeof(T) * (fCount - index)); 200 memcpy(fArray + index, fArray + newCount, sizeof(T)) [all...] |
/external/strace/ |
acinclude.m4 | 72 if (write (fileno (ctl), &cmd, sizeof cmd) < 0) 74 if (read (fileno (status), &pstatus, sizeof pstatus) < 0) 120 return write (fd, &cmd, sizeof cmd); 219 if (sizeof (off_t) == sizeof (long long) && 220 sizeof (off_t) > sizeof (long)) 242 if (sizeof (rlim_t) == sizeof (long long) && 243 sizeof (rlim_t) > sizeof (long) [all...] |
/frameworks/base/tests/BrowserTestPlugin/jni/ |
main.cpp | 71 #define ARRAY_COUNT(array) (sizeof(array) / sizeof(array[0])) 76 if (browserFuncs->size < sizeof(NPNetscapeFuncs)) { 81 browser = (NPNetscapeFuncs*) malloc(sizeof(NPNetscapeFuncs)); 82 memcpy(browser, browserFuncs, sizeof(NPNetscapeFuncs)); 86 pluginFuncs->size = sizeof(pluginFuncs); 106 { kCanvasInterfaceV0_ANPGetValue, sizeof(gCanvasI), &gCanvasI }, 107 { kLogInterfaceV0_ANPGetValue, sizeof(gLogI), &gLogI }, 108 { kPaintInterfaceV0_ANPGetValue, sizeof(gPaintI), &gPaintI }, 109 { kTypefaceInterfaceV0_ANPGetValue, sizeof(gTypefaceI), &gTypefaceI } [all...] |
/external/chromium/third_party/icu/source/test/cintltst/ |
utf8tst.c | 21 #define LENGTHOF(array) (sizeof(array)/sizeof((array)[0])) 94 for(i=0; i<sizeof(codeunit)/sizeof(codeunit[0]); i++){ 137 for(i=0; i<sizeof(codepoint)/sizeof(codepoint[0]); i=(int16_t)(i+2)){ 191 for(offset=0; offset<sizeof(input); offset++) { 192 if (offset < sizeof(input) - 1) { 206 U8_GET(input, 0, offset, sizeof(input), c); 211 UTF8_GET_CHAR_SAFE(input, 0, offset, sizeof(input), c, FALSE) [all...] |
/external/icu4c/test/cintltst/ |
utf8tst.c | 21 #define LENGTHOF(array) (sizeof(array)/sizeof((array)[0])) 94 for(i=0; i<sizeof(codeunit)/sizeof(codeunit[0]); i++){ 137 for(i=0; i<sizeof(codepoint)/sizeof(codepoint[0]); i=(int16_t)(i+2)){ 191 for(offset=0; offset<sizeof(input); offset++) { 192 if (offset < sizeof(input) - 1) { 206 U8_GET(input, 0, offset, sizeof(input), c); 211 UTF8_GET_CHAR_SAFE(input, 0, offset, sizeof(input), c, FALSE) [all...] |
/external/ipsec-tools/src/racoon/ |
grabmyaddr.c | 127 struct iovec iov = { buf, sizeof(buf) }; 137 (void*)&nladdr, sizeof(nladdr), 177 memset(rta_tb, 0, sizeof(rta_tb)); 178 parse_rtattr(rta_tb, IFA_MAX, IFA_RTA(m), h->nlmsg_len - NLMSG_LENGTH(sizeof(*m))); 185 I = malloc(sizeof(struct ifaddrs)); 188 memset(I, 0, sizeof(*I)); 229 memset(&nladdr, 0, sizeof(nladdr)); 232 req.nlh.nlmsg_len = sizeof(req); 239 if (sendto(fd, (void*)&req, sizeof(req), 0, (struct sockaddr*)&nladdr, sizeof(nladdr)) < 0) [all...] |
/external/chromium/sdch/open-vcdiff/src/ |
vcencoder_test.cc | 52 static const size_t kFileHeaderSize = sizeof(DeltaFileHeader); 150 : hashed_dictionary_(kDictionary, sizeof(kDictionary)), 154 simple_encoder_(kDictionary, sizeof(kDictionary)) { 207 sizeof(kDictionary), 219 sizeof(kDictionary), 233 sizeof(kDictionary), 245 decoder_.StartDecoding(kDictionary, sizeof(kDictionary)); 260 decoder_.StartDecoding(kDictionary, sizeof(kDictionary)); 284 decoder_.StartDecoding(kDictionary, sizeof(kDictionary)); 319 decoder_.StartDecoding(kDictionary, sizeof(kDictionary)) [all...] |