Lines Matching defs:count

96 size_t fread(void* const __pass_object_size0 buf, size_t size, size_t count, FILE* stream)
98 __clang_error_if(__unsafe_check_mul_overflow(size, count),
99 "in call to 'fread', size * count overflows")
100 __clang_error_if(__bos(buf) != __BIONIC_FORTIFY_UNKNOWN_SIZE && size * count > __bos(buf),
101 "in call to 'fread', size * count is too large for the given buffer") {
105 return __call_bypassing_fortify(fread)(buf, size, count, stream);
107 return __fread_chk(buf, size, count, stream, bos);
111 size_t fwrite(const void* const __pass_object_size0 buf, size_t size, size_t count, FILE* stream)
113 __clang_error_if(__unsafe_check_mul_overflow(size, count),
114 "in call to 'fwrite', size * count overflows")
115 __clang_error_if(__bos(buf) != __BIONIC_FORTIFY_UNKNOWN_SIZE && size * count > __bos(buf),
116 "in call to 'fwrite', size * count is too large for the given buffer") {
120 return __call_bypassing_fortify(fwrite)(buf, size, count, stream);
123 return __fwrite_chk(buf, size, count, stream, bos);
147 __errordecl(__fread_too_big_error, "fread called with size * count bigger than buffer");
148 __errordecl(__fread_overflow, "fread called with overflowing size * count");
155 __errordecl(__fwrite_too_big_error, "fwrite called with size * count bigger than buffer");
156 __errordecl(__fwrite_overflow, "fwrite called with overflowing size * count");
173 size_t fread(void* buf, size_t size, size_t count, FILE* stream) {
177 return __fread_real(buf, size, count, stream);
180 if (__builtin_constant_p(size) && __builtin_constant_p(count)) {
182 if (__size_mul_overflow(size, count, &total)) {
190 return __fread_real(buf, size, count, stream);
193 return __fread_chk(buf, size, count, stream, bos);
197 size_t fwrite(const void* buf, size_t size, size_t count, FILE* stream) {
201 return __fwrite_real(buf, size, count, stream);
204 if (__builtin_constant_p(size) && __builtin_constant_p(count)) {
206 if (__size_mul_overflow(size, count, &total)) {
214 return __fwrite_real(buf, size, count, stream);
217 return __fwrite_chk(buf, size, count, stream, bos);