| /xnu-8020.140.41/libkern/os/ |
| H A D | overflow.h | 60 #define os_mul_overflow(a, b, res) __os_warn_unused(__builtin_mul_overflow((a), (b), (res))) macro 79 _s = os_mul_overflow((a), (b), &_tmp); \ 80 _t = os_mul_overflow((c), _tmp, (res)); \ 89 _t = os_mul_overflow((x), _tmp, (res)); \ 97 _s = os_mul_overflow((a), (x), &_tmp); \
|
| /xnu-8020.140.41/iokit/DriverKit/ |
| H A D | safe_allocation.h | 212 if (__improbable(os_mul_overflow(n, sizeof(T), &bytes) || (n > UINT32_MAX))) { 230 if (__improbable(os_mul_overflow(n, sizeof(T), &bytes) || (n > UINT32_MAX))) {
|
| H A D | bounded_ptr.h | 394 if (__improbable(os_mul_overflow(n, sizeof(T), &bytes))) { 414 if (__improbable(os_mul_overflow(n, sizeof(T), &bytes))) {
|
| /xnu-8020.140.41/libkern/libkern/c++/ |
| H A D | safe_allocation.h | 212 if (__improbable(os_mul_overflow(n, sizeof(T), &bytes) || (n > UINT32_MAX))) { 230 if (__improbable(os_mul_overflow(n, sizeof(T), &bytes) || (n > UINT32_MAX))) {
|
| H A D | bounded_ptr.h | 394 if (__improbable(os_mul_overflow(n, sizeof(T), &bytes))) { 414 if (__improbable(os_mul_overflow(n, sizeof(T), &bytes))) {
|
| /xnu-8020.140.41/libsyscall/wrappers/spawn/ |
| H A D | posix_spawn.c | 925 if (os_mul_overflow(acts->pspa_alloc, 2, &newnum)) { in posix_spawn_growportactions_np() 1402 if (os_mul_overflow((*psactsp)->psfa_act_alloc, 2, &newnum)) { in _posix_spawn_file_actions_grow() 2139 if (os_mul_overflow(psmx->psmx_alloc, 2, &newnum)) { in posix_spawnattr_setmacpolicyinfo_np()
|
| /xnu-8020.140.41/bsd/kern/ |
| H A D | kern_core.c | 366 if (os_mul_overflow(segment_count, segment_command_sz, &lhs)) { in coredump()
|
| H A D | sysv_shm.c | 1063 if (os_mul_overflow(shminfo.shmmni, sizeof(struct shmid_kernel), &sz)) { in shminit()
|
| H A D | kdebug.c | 1775 if (os_mul_overflow(nthreads, sizeof(kd_threadmap), mapsize)) { in kdbg_thrmap_init_internal() 2349 if (os_mul_overflow(map_count, sizeof(kd_threadmap), &map_size)) { in _write_legacy_header()
|
| H A D | kern_event.c | 1404 if (os_mul_overflow((uint64_t)kev->ext[1], multiplier, &leeway_ns)) { in filt_timervalidate() 1424 if (os_mul_overflow((uint64_t)kev->data, multiplier, &calendar_deadline_ns)) { in filt_timervalidate() 1496 if (os_mul_overflow((uint64_t)kev->data, multiplier, &interval_ns)) { in filt_timervalidate() 8715 if (os_mul_overflow(sizeof(kqueue_id_t), buflen, &bufsize)) { in kevent_copyout_proc_dynkqids() 8746 if (os_mul_overflow(sizeof(kqueue_id_t), MIN(buflen, nkqueues), ©size)) { in kevent_copyout_proc_dynkqids()
|
| H A D | kern_aio.c | 1050 os_mul_overflow(sizeof(user_addr_t), uap->nent, &aiocbpp_size)) { in aio_suspend_nocancel()
|
| H A D | proc_info.c | 2909 if (os_mul_overflow(nuptrs, sizeof(uint64_t), ©size)) { in proc_pidlistuptrs()
|
| /xnu-8020.140.41/osfmk/kern/ |
| H A D | ledger.c | 128 if (os_mul_overflow(offset, sizeof(struct ledger_entry_small), &offset) || offset >= l->l_size) { in is_entry_valid() 220 …if (os_mul_overflow(lt_table_size, (sizeof(struct ledger_entry) / sizeof(struct ledger_entry_small… in ledger_template_entries_lut_size() 449 if (os_mul_overflow(old_cnt, 2, &new_cnt)) { in ledger_entry_add_with_flags()
|
| H A D | machine.c | 993 if (os_mul_overflow(timeout, scale, &timeout)) { in machine_timeout_init_with_suffix()
|
| H A D | kern_cdata.c | 94 if (os_mul_overflow(num_items, KCDATA_ALIGNMENT_SIZE - 1, &max_padding_bytes)) { in kcdata_estimate_required_buffer_size()
|
| H A D | debug.c | 488 if (os_mul_overflow(phys_carveout_mb, 1024 * 1024, &temp_phys_carveout_size)) { in phys_carveout_init()
|
| H A D | zalloc.c | 7702 if (os_mul_overflow(zc_auto, Z_CONTENTION_WMA_UNIT, &zc_auto)) { in compute_zone_working_set_size()
|
| /xnu-8020.140.41/bsd/net/classq/ |
| H A D | classq_fq_codel.c | 599 if (os_mul_overflow(fq_cl->fcl_stat.fcl_avg_qdelay, in fq_getq_flow()
|
| /xnu-8020.140.41/osfmk/ipc/ |
| H A D | ipc_kmsg.c | 1263 } else if (os_mul_overflow(user_descs, USER_DESC_MAX_DELTA, &max_delta)) { in ipc_kmsg_alloc() 3495 if (os_mul_overflow(count, sizeof(mach_port_t), &ports_length)) { in ipc_kmsg_copyin_ool_ports_descriptor() 3500 if (os_mul_overflow(count, sizeof(mach_port_name_t), &names_length)) { in ipc_kmsg_copyin_ool_ports_descriptor()
|
| /xnu-8020.140.41/iokit/Kernel/ |
| H A D | IODeviceTreeSupport.cpp | 1072 if (__improbable(os_mul_overflow(gIODTResolvers->alloc, 2, in IODTSetResolving()
|
| /xnu-8020.140.41/bsd/vfs/ |
| H A D | vfs_cache.c | 2477 if (os_mul_overflow(dNodes, 2, &nelements)) { in resize_namecache()
|
| /xnu-8020.140.41/bsd/netinet/ |
| H A D | flow_divert.c | 2915 if (os_mul_overflow(sizeof(*new_trie.nodes), (size_t)nodes_count, &nodes_mem_size) || in flow_divert_handle_app_map_create() 2917 os_mul_overflow(sizeof(*new_trie.bytes), (size_t)bytes_count, &bytes_mem_size) || in flow_divert_handle_app_map_create()
|
| /xnu-8020.140.41/tests/ |
| H A D | proc_info.c | 1970 if (os_mul_overflow(sizeof(kqueue_id_t), kqids_len, &kqids_size)) { in list_kqids()
|
| /xnu-8020.140.41/bsd/skywalk/mem/ |
| H A D | skmem_cache.c | 1072 } else if (os_mul_overflow(boff, 2, &boff)) { in skmem_slab_alloc_locked()
|
| /xnu-8020.140.41/osfmk/vm/ |
| H A D | vm_user.c | 2419 if (os_mul_overflow(*dispositions_count, sizeof(int), &disp_buf_req_size)) { in mach_vm_page_range_query()
|