Lines Matching refs:res

126   SIZE_T res = REAL(fread_unlocked)(ptr, size, nmemb, file);  in INTERCEPTOR()  local
127 if (res > 0) in INTERCEPTOR()
128 __msan_unpoison(ptr, res *size); in INTERCEPTOR()
129 return res; in INTERCEPTOR()
147 void *res = REAL(memccpy)(dest, src, c, n); in INTERCEPTOR() local
148 CHECK(!res || (res >= dest && res <= (char *)dest + n)); in INTERCEPTOR()
149 SIZE_T sz = res ? (char *)res - (char *)dest : n; in INTERCEPTOR()
152 return res; in INTERCEPTOR()
162 int res = msan_posix_memalign(memptr, alignment, size, &stack); in INTERCEPTOR() local
163 if (!res) in INTERCEPTOR()
165 return res; in INTERCEPTOR()
286 char *res = REAL(strcpy)(dest, src); in INTERCEPTOR() local
288 return res; in INTERCEPTOR()
297 char *res = REAL(strncpy)(dest, src, n); in INTERCEPTOR() local
300 return res; in INTERCEPTOR()
309 char *res = REAL(stpcpy)(dest, src); in INTERCEPTOR() local
311 return res; in INTERCEPTOR()
318 char *res = REAL(stpncpy)(dest, src, n); in INTERCEPTOR() local
321 return res; in INTERCEPTOR()
337 char *res = REAL(strdup)(src); in INTERCEPTOR() local
338 CopyShadowAndOrigin(res, src, n + 1, &stack); in INTERCEPTOR()
339 return res; in INTERCEPTOR()
348 char *res = REAL(__strdup)(src); in INTERCEPTOR() local
349 CopyShadowAndOrigin(res, src, n + 1, &stack); in INTERCEPTOR()
350 return res; in INTERCEPTOR()
360 char *res = REAL(gcvt)(number, ndigit, buf); in INTERCEPTOR() local
363 return res; in INTERCEPTOR()
377 char *res = REAL(strcat)(dest, src); in INTERCEPTOR() local
379 return res; in INTERCEPTOR()
388 char *res = REAL(strncat)(dest, src, n); in INTERCEPTOR() local
391 return res; in INTERCEPTOR()
398 ret_type res = REAL(func)(__VA_ARGS__); \
400 return res;
481 int res = REAL(vswprintf)(str, size, format, ap); local
482 if (res >= 0) {
483 __msan_unpoison(str, 4 * (res + 1));
485 return res;
492 int res = vswprintf(str, size, format, ap); in INTERCEPTOR() local
494 return res; in INTERCEPTOR()
500 ret_type res = REAL(func)(s, __VA_ARGS__); \
501 if (s) __msan_unpoison(s, sizeof(char_type) * (res + 1)); \
502 return res;
549 int res = REAL(mbtowc)(dest, src, n); in INTERCEPTOR() local
550 if (res != -1 && dest) __msan_unpoison(dest, sizeof(wchar_t)); in INTERCEPTOR()
551 return res; in INTERCEPTOR()
557 SIZE_T res = REAL(mbrtowc)(dest, src, n, ps); in INTERCEPTOR() local
558 if (res != (SIZE_T)-1 && dest) __msan_unpoison(dest, sizeof(wchar_t)); in INTERCEPTOR()
559 return res; in INTERCEPTOR()
566 wchar_t *res = REAL(wmemcpy)(dest, src, n); in INTERCEPTOR() local
568 return res; in INTERCEPTOR()
575 wchar_t *res = REAL(wmempcpy)(dest, src, n); in INTERCEPTOR() local
577 return res; in INTERCEPTOR()
587 wchar_t *res = REAL(wmemset)(s, c, n); in INTERCEPTOR() local
589 return res; in INTERCEPTOR()
595 wchar_t *res = REAL(wmemmove)(dest, src, n); in INTERCEPTOR() local
597 return res; in INTERCEPTOR()
602 int res = REAL(wcscmp)(s1, s2); in INTERCEPTOR() local
603 return res; in INTERCEPTOR()
608 int res = REAL(gettimeofday)(tv, tz); in INTERCEPTOR() local
613 return res; in INTERCEPTOR()
619 char *res = REAL(fcvt)(x, a, b, c); in INTERCEPTOR() local
622 if (res) in INTERCEPTOR()
623 __msan_unpoison(res, internal_strlen(res) + 1); in INTERCEPTOR()
624 return res; in INTERCEPTOR()
635 char *res = REAL(getenv)(name); in INTERCEPTOR() local
636 if (res) in INTERCEPTOR()
637 __msan_unpoison(res, internal_strlen(res) + 1); in INTERCEPTOR()
638 return res; in INTERCEPTOR()
656 int res = REAL(setenv)(name, value, overwrite); in INTERCEPTOR() local
657 if (!res) UnpoisonEnviron(); in INTERCEPTOR()
658 return res; in INTERCEPTOR()
663 int res = REAL(putenv)(string); in INTERCEPTOR() local
664 if (!res) UnpoisonEnviron(); in INTERCEPTOR()
665 return res; in INTERCEPTOR()
672 int res = REAL(fstat)(fd, buf); in INTERCEPTOR() local
673 if (!res) in INTERCEPTOR()
675 return res; in INTERCEPTOR()
685 int res = REAL(fstat64)(fd, buf); in INTERCEPTOR() local
686 if (!res) in INTERCEPTOR()
688 return res; in INTERCEPTOR()
698 int res = REAL(__fxstat)(magic, fd, buf); in INTERCEPTOR() local
699 if (!res) in INTERCEPTOR()
701 return res; in INTERCEPTOR()
711 int res = REAL(__fxstat64)(magic, fd, buf); in INTERCEPTOR() local
712 if (!res) in INTERCEPTOR()
714 return res; in INTERCEPTOR()
724 int res = REAL(fstatat)(fd, pathname, buf, flags); in INTERCEPTOR() local
725 if (!res) __msan_unpoison(buf, __sanitizer::struct_stat_sz); in INTERCEPTOR()
726 return res; in INTERCEPTOR()
736 int res = REAL(fstatat64)(fd, pathname, buf, flags); in INTERCEPTOR() local
737 if (!res) in INTERCEPTOR()
739 return res; in INTERCEPTOR()
750 int res = REAL(__fxstatat)(magic, fd, pathname, buf, flags); in INTERCEPTOR() local
751 if (!res) __msan_unpoison(buf, __sanitizer::struct_stat_sz); in INTERCEPTOR()
752 return res; in INTERCEPTOR()
763 int res = REAL(__fxstatat64)(magic, fd, pathname, buf, flags); in INTERCEPTOR() local
764 if (!res) __msan_unpoison(buf, __sanitizer::struct_stat64_sz); in INTERCEPTOR()
765 return res; in INTERCEPTOR()
776 int res = REAL(pipe)(pipefd); in INTERCEPTOR() local
777 if (!res) in INTERCEPTOR()
779 return res; in INTERCEPTOR()
784 int res = REAL(pipe2)(pipefd, flags); in INTERCEPTOR() local
785 if (!res) in INTERCEPTOR()
787 return res; in INTERCEPTOR()
792 int res = REAL(socketpair)(domain, type, protocol, sv); in INTERCEPTOR() local
793 if (!res) in INTERCEPTOR()
795 return res; in INTERCEPTOR()
801 char *res = REAL(fgets_unlocked)(s, size, stream); in INTERCEPTOR() local
802 if (res) in INTERCEPTOR()
804 return res; in INTERCEPTOR()
815 int res = REAL(func)(resource, rlim); \
816 if (!res) \
818 return res
832 int res = REAL(getrlimit64)(resource, rlim); in INTERCEPTOR() local
833 if (!res) __msan_unpoison(rlim, __sanitizer::struct_rlimit64_sz); in INTERCEPTOR()
834 return res; in INTERCEPTOR()
843 int res = REAL(prlimit)(pid, resource, new_rlimit, old_rlimit); in INTERCEPTOR() local
844 if (!res) __msan_unpoison(old_rlimit, __sanitizer::struct_rlimit_sz); in INTERCEPTOR()
845 return res; in INTERCEPTOR()
854 int res = REAL(prlimit64)(pid, resource, new_rlimit, old_rlimit); in INTERCEPTOR() local
855 if (!res) __msan_unpoison(old_rlimit, __sanitizer::struct_rlimit64_sz); in INTERCEPTOR()
856 return res; in INTERCEPTOR()
872 int res = REAL(gethostname)(name, len); in INTERCEPTOR() local
873 if (!res || (res == -1 && errno == errno_ENAMETOOLONG)) { in INTERCEPTOR()
879 return res; in INTERCEPTOR()
886 int res = REAL(epoll_wait)(epfd, events, maxevents, timeout); in INTERCEPTOR() local
887 if (res > 0) { in INTERCEPTOR()
888 __msan_unpoison(events, __sanitizer::struct_epoll_event_sz * res); in INTERCEPTOR()
890 return res; in INTERCEPTOR()
901 int res = REAL(epoll_pwait)(epfd, events, maxevents, timeout, sigmask); in INTERCEPTOR() local
902 if (res > 0) { in INTERCEPTOR()
903 __msan_unpoison(events, __sanitizer::struct_epoll_event_sz * res); in INTERCEPTOR()
905 return res; in INTERCEPTOR()
988 void *res = real_mmap(addr, length, prot, flags, fd, offset); in mmap_interceptor() local
989 if (res != (void *)-1) { in mmap_interceptor()
990 void *end_res = (char *)res + (rounded_length - 1); in mmap_interceptor()
991 if (MEM_IS_APP(res) && MEM_IS_APP(end_res)) { in mmap_interceptor()
992 __msan_unpoison(res, rounded_length); in mmap_interceptor()
996 internal_munmap(res, length); in mmap_interceptor()
1001 return res; in mmap_interceptor()
1006 int res = REAL(getrusage)(who, usage); in INTERCEPTOR() local
1007 if (res == 0) { in INTERCEPTOR()
1010 return res; in INTERCEPTOR()
1090 int res = REAL(pthread_create)(th, attr, MsanThreadStartFunc, t); in INTERCEPTOR() local
1094 if (!res) { in INTERCEPTOR()
1097 return res; in INTERCEPTOR()
1104 int res = REAL(pthread_key_create)(key, dtor); in INTERCEPTOR() local
1105 if (!res && key) in INTERCEPTOR()
1107 return res; in INTERCEPTOR()
1118 int res = REAL(pthread_join)(th, retval); in INTERCEPTOR() local
1119 if (!res && retval) in INTERCEPTOR()
1121 return res; in INTERCEPTOR()
1207 int res; in setup_at_exit_wrapper() local
1214 res = REAL(__cxa_atexit)((void (*)(void *a))MSanAtExitWrapper, 0, 0); in setup_at_exit_wrapper()
1215 if (!res) { in setup_at_exit_wrapper()
1219 res = REAL(__cxa_atexit)(MSanCxaAtExitWrapper, r, dso); in setup_at_exit_wrapper()
1221 return res; in setup_at_exit_wrapper()
1249 int res = REAL(openpty)(aparent, aworker, name, termp, winp); in INTERCEPTOR() local
1250 if (!res) { in INTERCEPTOR()
1254 return res; in INTERCEPTOR()
1268 int res = REAL(forkpty)(aparent, name, termp, winp); in INTERCEPTOR() local
1269 if (res != -1) in INTERCEPTOR()
1271 return res; in INTERCEPTOR()
1433 int res; in sigaction_impl() local
1450 res = REAL(SIGACTION_SYMNAME)(signo, pnew_act, oldact); in sigaction_impl()
1451 if (res == 0 && oldact) { in sigaction_impl()
1458 res = REAL(SIGACTION_SYMNAME)(signo, act, oldact); in sigaction_impl()
1461 if (res == 0 && oldact) { in sigaction_impl()
1464 return res; in sigaction_impl()
1497 const char *res = REAL(strsignal)(sig); in INTERCEPTOR() local
1498 if (res) in INTERCEPTOR()
1499 __msan_unpoison(res, internal_strlen(res) + 1); in INTERCEPTOR()
1500 return res; in INTERCEPTOR()
1513 int res = REAL(dladdr)(addr, info); in INTERCEPTOR() local
1514 if (res != 0) { in INTERCEPTOR()
1521 return res; in INTERCEPTOR()
1527 char *res = REAL(dlerror)(fake); in INTERCEPTOR() local
1528 if (res) in INTERCEPTOR()
1529 __msan_unpoison(res, internal_strlen(res) + 1); in INTERCEPTOR()
1530 return res; in INTERCEPTOR()
1559 int res = REAL(shmctl)(shmid, shmctl_ipc_stat, &ds); in INTERCEPTOR() local
1560 if (!res) { in INTERCEPTOR()
1573 int res = REAL(dl_iterate_phdr)(msan_dl_iterate_phdr_cb, (void *)&cbdata); in INTERCEPTOR() local
1574 return res; in INTERCEPTOR()
1580 wchar_t *res = REAL(wcschr)(s, wc, ps); in INTERCEPTOR() local
1581 return res; in INTERCEPTOR()
1588 wchar_t *res = REAL(wcscpy)(dest, src); in INTERCEPTOR() local
1591 return res; in INTERCEPTOR()
1599 wchar_t *res = REAL(wcsncpy)(dest, src, n); in INTERCEPTOR() local
1602 return res; in INTERCEPTOR()
1635 void *res = REAL(memcpy)(dest, src, n); in __msan_memcpy() local
1637 return res; in __msan_memcpy()
1644 void *res = REAL(memset)(s, c, n); in __msan_memset() local
1646 return res; in __msan_memset()
1654 void *res = REAL(memmove)(dest, src, n); in __msan_memmove() local
1656 return res; in __msan_memmove()