Flawfinder version 2.0.10, (C) 2001-2019 David A. Wheeler.
Number of rules (primarily dangerous function names) in C/C++ ruleset: 223
Examining data/apitrace-9.0+repack/cli/cli.hpp
Examining data/apitrace-9.0+repack/cli/cli_diff.cpp
Examining data/apitrace-9.0+repack/cli/cli_diff_images.cpp
Examining data/apitrace-9.0+repack/cli/cli_diff_state.cpp
Examining data/apitrace-9.0+repack/cli/cli_dump.cpp
Examining data/apitrace-9.0+repack/cli/cli_dump_images.cpp
Examining data/apitrace-9.0+repack/cli/cli_leaks.cpp
Examining data/apitrace-9.0+repack/cli/cli_main.cpp
Examining data/apitrace-9.0+repack/cli/cli_pager.cpp
Examining data/apitrace-9.0+repack/cli/cli_pager.hpp
Examining data/apitrace-9.0+repack/cli/cli_pickle.cpp
Examining data/apitrace-9.0+repack/cli/cli_repack.cpp
Examining data/apitrace-9.0+repack/cli/cli_resources.cpp
Examining data/apitrace-9.0+repack/cli/cli_resources.hpp
Examining data/apitrace-9.0+repack/cli/cli_retrace.cpp
Examining data/apitrace-9.0+repack/cli/cli_retrace.hpp
Examining data/apitrace-9.0+repack/cli/cli_sed.cpp
Examining data/apitrace-9.0+repack/cli/cli_trace.cpp
Examining data/apitrace-9.0+repack/cli/cli_trim.cpp
Examining data/apitrace-9.0+repack/cli/pickle.hpp
Examining data/apitrace-9.0+repack/compat/cxx_compat.hpp
Examining data/apitrace-9.0+repack/compat/winsdk_compat.h
Examining data/apitrace-9.0+repack/dispatch/d2dimports.hpp
Examining data/apitrace-9.0+repack/dispatch/d3d10imports.hpp
Examining data/apitrace-9.0+repack/dispatch/d3d11imports.hpp
Examining data/apitrace-9.0+repack/dispatch/d3d8imports.hpp
Examining data/apitrace-9.0+repack/dispatch/d3d9imports.hpp
Examining data/apitrace-9.0+repack/dispatch/d3dimports.hpp
Examining data/apitrace-9.0+repack/dispatch/dcompimports.hpp
Examining data/apitrace-9.0+repack/dispatch/dlopen.hpp
Examining data/apitrace-9.0+repack/dispatch/dxgiint.h
Examining data/apitrace-9.0+repack/dispatch/dxva2imports.hpp
Examining data/apitrace-9.0+repack/dispatch/eglimports.hpp
Examining data/apitrace-9.0+repack/dispatch/glimports.hpp
Examining data/apitrace-9.0+repack/dispatch/glproc_egl.cpp
Examining data/apitrace-9.0+repack/dispatch/glproc_gl.cpp
Examining data/apitrace-9.0+repack/gui/apicalldelegate.cpp
Examining data/apitrace-9.0+repack/gui/apicalldelegate.h
Examining data/apitrace-9.0+repack/gui/apisurface.cpp
Examining data/apitrace-9.0+repack/gui/apisurface.h
Examining data/apitrace-9.0+repack/gui/apitrace.cpp
Examining data/apitrace-9.0+repack/gui/apitrace.h
Examining data/apitrace-9.0+repack/gui/apitracecall.cpp
Examining data/apitrace-9.0+repack/gui/apitracecall.h
Examining data/apitrace-9.0+repack/gui/apitracefilter.cpp
Examining data/apitrace-9.0+repack/gui/apitracefilter.h
Examining data/apitrace-9.0+repack/gui/apitracemodel.cpp
Examining data/apitrace-9.0+repack/gui/apitracemodel.h
Examining data/apitrace-9.0+repack/gui/argumentseditor.cpp
Examining data/apitrace-9.0+repack/gui/argumentseditor.h
Examining data/apitrace-9.0+repack/gui/calldurationgraph.h
Examining data/apitrace-9.0+repack/gui/glsledit.cpp
Examining data/apitrace-9.0+repack/gui/glsledit.h
Examining data/apitrace-9.0+repack/gui/graphing/frameaxiswidget.cpp
Examining data/apitrace-9.0+repack/gui/graphing/frameaxiswidget.h
Examining data/apitrace-9.0+repack/gui/graphing/graphaxiswidget.cpp
Examining data/apitrace-9.0+repack/gui/graphing/graphaxiswidget.h
Examining data/apitrace-9.0+repack/gui/graphing/graphing.h
Examining data/apitrace-9.0+repack/gui/graphing/graphlabelwidget.h
Examining data/apitrace-9.0+repack/gui/graphing/graphview.cpp
Examining data/apitrace-9.0+repack/gui/graphing/graphview.h
Examining data/apitrace-9.0+repack/gui/graphing/graphwidget.cpp
Examining data/apitrace-9.0+repack/gui/graphing/graphwidget.h
Examining data/apitrace-9.0+repack/gui/graphing/heatmapverticalaxiswidget.cpp
Examining data/apitrace-9.0+repack/gui/graphing/heatmapverticalaxiswidget.h
Examining data/apitrace-9.0+repack/gui/graphing/heatmapview.cpp
Examining data/apitrace-9.0+repack/gui/graphing/heatmapview.h
Examining data/apitrace-9.0+repack/gui/graphing/histogramview.cpp
Examining data/apitrace-9.0+repack/gui/graphing/histogramview.h
Examining data/apitrace-9.0+repack/gui/graphing/timeaxiswidget.cpp
Examining data/apitrace-9.0+repack/gui/graphing/timeaxiswidget.h
Examining data/apitrace-9.0+repack/gui/imageviewer.cpp
Examining data/apitrace-9.0+repack/gui/imageviewer.h
Examining data/apitrace-9.0+repack/gui/jumpwidget.cpp
Examining data/apitrace-9.0+repack/gui/jumpwidget.h
Examining data/apitrace-9.0+repack/gui/leaktracethread.cpp
Examining data/apitrace-9.0+repack/gui/leaktracethread.h
Examining data/apitrace-9.0+repack/gui/main.cpp
Examining data/apitrace-9.0+repack/gui/mainwindow.cpp
Examining data/apitrace-9.0+repack/gui/mainwindow.h
Examining data/apitrace-9.0+repack/gui/pixelwidget.cpp
Examining data/apitrace-9.0+repack/gui/pixelwidget.h
Examining data/apitrace-9.0+repack/gui/profiledialog.cpp
Examining data/apitrace-9.0+repack/gui/profiledialog.h
Examining data/apitrace-9.0+repack/gui/profileheatmap.h
Examining data/apitrace-9.0+repack/gui/profiletablemodel.cpp
Examining data/apitrace-9.0+repack/gui/profiletablemodel.h
Examining data/apitrace-9.0+repack/gui/profiling.h
Examining data/apitrace-9.0+repack/gui/qubjson.cpp
Examining data/apitrace-9.0+repack/gui/qubjson.h
Examining data/apitrace-9.0+repack/gui/qubjson_test.cpp
Examining data/apitrace-9.0+repack/gui/retracer.cpp
Examining data/apitrace-9.0+repack/gui/retracer.h
Examining data/apitrace-9.0+repack/gui/saverthread.cpp
Examining data/apitrace-9.0+repack/gui/saverthread.h
Examining data/apitrace-9.0+repack/gui/searchwidget.cpp
Examining data/apitrace-9.0+repack/gui/searchwidget.h
Examining data/apitrace-9.0+repack/gui/settingsdialog.cpp
Examining data/apitrace-9.0+repack/gui/settingsdialog.h
Examining data/apitrace-9.0+repack/gui/shaderssourcewidget.cpp
Examining data/apitrace-9.0+repack/gui/shaderssourcewidget.h
Examining data/apitrace-9.0+repack/gui/thumbnail.h
Examining data/apitrace-9.0+repack/gui/tracedialog.cpp
Examining data/apitrace-9.0+repack/gui/tracedialog.h
Examining data/apitrace-9.0+repack/gui/traceloader.cpp
Examining data/apitrace-9.0+repack/gui/traceloader.h
Examining data/apitrace-9.0+repack/gui/traceprocess.cpp
Examining data/apitrace-9.0+repack/gui/traceprocess.h
Examining data/apitrace-9.0+repack/gui/trimprocess.cpp
Examining data/apitrace-9.0+repack/gui/trimprocess.h
Examining data/apitrace-9.0+repack/gui/vertexdatainterpreter.cpp
Examining data/apitrace-9.0+repack/gui/vertexdatainterpreter.h
Examining data/apitrace-9.0+repack/helpers/com_ptr.hpp
Examining data/apitrace-9.0+repack/helpers/d3d10size.hpp
Examining data/apitrace-9.0+repack/helpers/d3d11size.hpp
Examining data/apitrace-9.0+repack/helpers/d3d7size.hpp
Examining data/apitrace-9.0+repack/helpers/d3d8size.hpp
Examining data/apitrace-9.0+repack/helpers/d3d9size.hpp
Examining data/apitrace-9.0+repack/helpers/d3dcommonsize.hpp
Examining data/apitrace-9.0+repack/helpers/d3dshader.cpp
Examining data/apitrace-9.0+repack/helpers/d3dshader.hpp
Examining data/apitrace-9.0+repack/helpers/dxgisize.hpp
Examining data/apitrace-9.0+repack/helpers/eglsize.cpp
Examining data/apitrace-9.0+repack/helpers/eglsize.hpp
Examining data/apitrace-9.0+repack/helpers/glfeatures.cpp
Examining data/apitrace-9.0+repack/helpers/glfeatures.hpp
Examining data/apitrace-9.0+repack/helpers/glsize.hpp
Examining data/apitrace-9.0+repack/helpers/halffloat.hpp
Examining data/apitrace-9.0+repack/inject/inject.h
Examining data/apitrace-9.0+repack/inject/injectee_iat.cpp
Examining data/apitrace-9.0+repack/inject/injectee_mhook.cpp
Examining data/apitrace-9.0+repack/inject/injector.cpp
Examining data/apitrace-9.0+repack/lib/guids/guids.cpp
Examining data/apitrace-9.0+repack/lib/guids/guids.hpp
Examining data/apitrace-9.0+repack/lib/guids/guids_defs.hpp
Examining data/apitrace-9.0+repack/lib/guids/guids_entries.h
Examining data/apitrace-9.0+repack/lib/guids/guids_test.cpp
Examining data/apitrace-9.0+repack/lib/highlight/highlight.cpp
Examining data/apitrace-9.0+repack/lib/highlight/highlight.hpp
Examining data/apitrace-9.0+repack/lib/image/image.hpp
Examining data/apitrace-9.0+repack/lib/image/image_bmp.cpp
Examining data/apitrace-9.0+repack/lib/image/image_png.cpp
Examining data/apitrace-9.0+repack/lib/image/image_pnm.cpp
Examining data/apitrace-9.0+repack/lib/image/image_raw.cpp
Examining data/apitrace-9.0+repack/lib/image/image_md5.cpp
Examining data/apitrace-9.0+repack/lib/os/os.hpp
Examining data/apitrace-9.0+repack/lib/os/os_backtrace.cpp
Examining data/apitrace-9.0+repack/lib/os/os_backtrace.hpp
Examining data/apitrace-9.0+repack/lib/os/os_binary.hpp
Examining data/apitrace-9.0+repack/lib/os/os_crtdbg.cpp
Examining data/apitrace-9.0+repack/lib/os/os_crtdbg.hpp
Examining data/apitrace-9.0+repack/lib/os/os_dl.hpp
Examining data/apitrace-9.0+repack/lib/os/os_memory.hpp
Examining data/apitrace-9.0+repack/lib/os/os_posix.cpp
Examining data/apitrace-9.0+repack/lib/os/os_process.hpp
Examining data/apitrace-9.0+repack/lib/os/os_string.hpp
Examining data/apitrace-9.0+repack/lib/os/os_symbols.hpp
Examining data/apitrace-9.0+repack/lib/os/os_thread.hpp
Examining data/apitrace-9.0+repack/lib/os/os_thread_test.cpp
Examining data/apitrace-9.0+repack/lib/os/os_time.hpp
Examining data/apitrace-9.0+repack/lib/os/os_version.hpp
Examining data/apitrace-9.0+repack/lib/os/os_win32.cpp
Examining data/apitrace-9.0+repack/lib/os/thread_pool.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_api.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_callset.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_callset.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_dump.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_dump.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_dump_internal.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_fast_callset.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_fast_callset.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_file.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_file.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_file_brotli.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_file_read.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_file_snappy.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_file_zlib.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_format.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_lookup.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_model.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_model.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_option.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_option.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_ostream.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_ostream_snappy.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_ostream_zlib.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_parser.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_parser.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_parser_flags.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_parser_flags_test.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_parser_loop.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_profiler.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_profiler.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_snappy.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_writer.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_writer.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp
Examining data/apitrace-9.0+repack/lib/trace/trace_writer_local.hpp
Examining data/apitrace-9.0+repack/lib/trace/trace_writer_model.cpp
Examining data/apitrace-9.0+repack/lib/ubjson/ubjson.hpp
Examining data/apitrace-9.0+repack/retrace/d3d10state.cpp
Examining data/apitrace-9.0+repack/retrace/d3d10state.hpp
Examining data/apitrace-9.0+repack/retrace/d3d10state_images.cpp
Examining data/apitrace-9.0+repack/retrace/d3d11state.cpp
Examining data/apitrace-9.0+repack/retrace/d3d11state.hpp
Examining data/apitrace-9.0+repack/retrace/d3d11state_images.cpp
Examining data/apitrace-9.0+repack/retrace/d3d7state.cpp
Examining data/apitrace-9.0+repack/retrace/d3d7state_images.cpp
Examining data/apitrace-9.0+repack/retrace/d3d8state.cpp
Examining data/apitrace-9.0+repack/retrace/d3d8state_images.cpp
Examining data/apitrace-9.0+repack/retrace/d3d9state.cpp
Examining data/apitrace-9.0+repack/retrace/d3d9state.hpp
Examining data/apitrace-9.0+repack/retrace/d3d9state_formats.cpp
Examining data/apitrace-9.0+repack/retrace/d3d9state_images.cpp
Examining data/apitrace-9.0+repack/retrace/d3dretrace.hpp
Examining data/apitrace-9.0+repack/retrace/d3dretrace_dxgi.hpp
Examining data/apitrace-9.0+repack/retrace/d3dretrace_dxgi_misc.cpp
Examining data/apitrace-9.0+repack/retrace/d3dretrace_dxgi_priv.cpp
Examining data/apitrace-9.0+repack/retrace/d3dretrace_main.cpp
Examining data/apitrace-9.0+repack/retrace/d3dretrace_ws.cpp
Examining data/apitrace-9.0+repack/retrace/d3dstate.hpp
Examining data/apitrace-9.0+repack/retrace/dxgistate.cpp
Examining data/apitrace-9.0+repack/retrace/dxgistate.hpp
Examining data/apitrace-9.0+repack/retrace/dxgistate_so.hpp
Examining data/apitrace-9.0+repack/retrace/glretrace.hpp
Examining data/apitrace-9.0+repack/retrace/glretrace_cgl.cpp
Examining data/apitrace-9.0+repack/retrace/glretrace_egl.cpp
Examining data/apitrace-9.0+repack/retrace/glretrace_glx.cpp
Examining data/apitrace-9.0+repack/retrace/glretrace_main.cpp
Examining data/apitrace-9.0+repack/retrace/glretrace_wgl.cpp
Examining data/apitrace-9.0+repack/retrace/glretrace_wgl.hpp
Examining data/apitrace-9.0+repack/retrace/glretrace_wgl_font_bitmaps.cpp
Examining data/apitrace-9.0+repack/retrace/glretrace_wgl_font_outlines.cpp
Examining data/apitrace-9.0+repack/retrace/glretrace_ws.cpp
Examining data/apitrace-9.0+repack/retrace/glstate.cpp
Examining data/apitrace-9.0+repack/retrace/glstate.hpp
Examining data/apitrace-9.0+repack/retrace/glstate_formats.cpp
Examining data/apitrace-9.0+repack/retrace/glstate_images.cpp
Examining data/apitrace-9.0+repack/retrace/glstate_internal.hpp
Examining data/apitrace-9.0+repack/retrace/glstate_shaders.cpp
Examining data/apitrace-9.0+repack/retrace/glws.cpp
Examining data/apitrace-9.0+repack/retrace/glws.hpp
Examining data/apitrace-9.0+repack/retrace/glws_egl_xlib.cpp
Examining data/apitrace-9.0+repack/retrace/glws_glx.cpp
Examining data/apitrace-9.0+repack/retrace/glws_waffle.cpp
Examining data/apitrace-9.0+repack/retrace/glws_wgl.cpp
Examining data/apitrace-9.0+repack/retrace/glws_xlib.cpp
Examining data/apitrace-9.0+repack/retrace/glws_xlib.hpp
Examining data/apitrace-9.0+repack/retrace/json.cpp
Examining data/apitrace-9.0+repack/retrace/json.hpp
Examining data/apitrace-9.0+repack/retrace/metric_backend.hpp
Examining data/apitrace-9.0+repack/retrace/metric_backend_amd_perfmon.cpp
Examining data/apitrace-9.0+repack/retrace/metric_backend_amd_perfmon.hpp
Examining data/apitrace-9.0+repack/retrace/metric_backend_intel_perfquery.cpp
Examining data/apitrace-9.0+repack/retrace/metric_backend_intel_perfquery.hpp
Examining data/apitrace-9.0+repack/retrace/metric_backend_opengl.cpp
Examining data/apitrace-9.0+repack/retrace/metric_backend_opengl.hpp
Examining data/apitrace-9.0+repack/retrace/metric_helper.cpp
Examining data/apitrace-9.0+repack/retrace/metric_writer.cpp
Examining data/apitrace-9.0+repack/retrace/metric_writer.hpp
Examining data/apitrace-9.0+repack/retrace/mmap_allocator.hpp
Examining data/apitrace-9.0+repack/retrace/process_name.cpp
Examining data/apitrace-9.0+repack/retrace/process_name.hpp
Examining data/apitrace-9.0+repack/retrace/retrace.cpp
Examining data/apitrace-9.0+repack/retrace/retrace.hpp
Examining data/apitrace-9.0+repack/retrace/retrace_main.cpp
Examining data/apitrace-9.0+repack/retrace/retrace_stdc.cpp
Examining data/apitrace-9.0+repack/retrace/retrace_swizzle.cpp
Examining data/apitrace-9.0+repack/retrace/retrace_swizzle.hpp
Examining data/apitrace-9.0+repack/retrace/scoped_allocator.hpp
Examining data/apitrace-9.0+repack/retrace/state_writer.cpp
Examining data/apitrace-9.0+repack/retrace/state_writer.hpp
Examining data/apitrace-9.0+repack/retrace/state_writer_json.cpp
Examining data/apitrace-9.0+repack/retrace/state_writer_ubjson.cpp
Examining data/apitrace-9.0+repack/retrace/threaded_snapshot.hpp
Examining data/apitrace-9.0+repack/retrace/ws.cpp
Examining data/apitrace-9.0+repack/retrace/ws.hpp
Examining data/apitrace-9.0+repack/retrace/ws_win32.cpp
Examining data/apitrace-9.0+repack/retrace/ws_win32.hpp
Examining data/apitrace-9.0+repack/specs/scripts/cxx2api.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/common/constants.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/common/context.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/common/dictionary.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/common/dictionary.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/common/platform.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/common/transform.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/common/transform.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/common/version.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/dec/bit_reader.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/dec/bit_reader.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/dec/huffman.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/dec/huffman.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/dec/prefix.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/dec/state.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/dec/state.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/backward_references.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/backward_references.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/backward_references_hq.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/backward_references_hq.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/backward_references_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/bit_cost.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/bit_cost.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/bit_cost_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/block_encoder_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/block_splitter.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/block_splitter.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/block_splitter_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/brotli_bit_stream.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/brotli_bit_stream.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/cluster.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/cluster.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/cluster_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/command.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/dictionary_hash.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/dictionary_hash.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encoder_dict.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encoder_dict.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/entropy_encode.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/entropy_encode.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/entropy_encode_static.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/fast_log.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/find_match_length.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/hash.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/hash_composite_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/hash_forgetful_chain_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/hash_longest_match64_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/hash_longest_match_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/hash_longest_match_quickly_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/hash_rolling_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/hash_to_binary_tree_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/histogram.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/histogram.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/histogram_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/literal_cost.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/literal_cost.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/memory.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/memory.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/metablock.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/metablock.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/metablock_inc.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/params.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/prefix.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/quality.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/ringbuffer.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/static_dict.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/static_dict.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/static_dict_lut.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/utf8_util.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/utf8_util.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/enc/write_bits.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/fuzz/decode_fuzzer.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/fuzz/run_decode_fuzzer.c
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/include/brotli/decode.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/include/brotli/encode.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/include/brotli/port.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/include/brotli/types.h
Examining data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c
Examining data/apitrace-9.0+repack/thirdparty/crc32c/crc32c.c
Examining data/apitrace-9.0+repack/thirdparty/crc32c/crc32c.hpp
Examining data/apitrace-9.0+repack/thirdparty/khronos/EGL/egl.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/EGL/eglext.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/EGL/eglplatform.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GL/gl.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GL/glx.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GL/wglext.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GLES/gl.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GLES/glext.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GLES/glplatform.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2ext.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2platform.h
Examining data/apitrace-9.0+repack/thirdparty/khronos/KHR/khrplatform.h
Examining data/apitrace-9.0+repack/wrappers/assert.cpp
Examining data/apitrace-9.0+repack/wrappers/config.cpp
Examining data/apitrace-9.0+repack/wrappers/config.hpp
Examining data/apitrace-9.0+repack/wrappers/d3d9shader.cpp
Examining data/apitrace-9.0+repack/wrappers/d3d9shader.hpp
Examining data/apitrace-9.0+repack/wrappers/d3dcommonshader.cpp
Examining data/apitrace-9.0+repack/wrappers/d3dcommonshader.hpp
Examining data/apitrace-9.0+repack/wrappers/dlltrace.hpp
Examining data/apitrace-9.0+repack/wrappers/dlsym.cpp
Examining data/apitrace-9.0+repack/wrappers/dxgitrace.hpp
Examining data/apitrace-9.0+repack/wrappers/glcaps.cpp
Examining data/apitrace-9.0+repack/wrappers/glmemshadow.cpp
Examining data/apitrace-9.0+repack/wrappers/glmemshadow.hpp
Examining data/apitrace-9.0+repack/wrappers/gltrace.hpp
Examining data/apitrace-9.0+repack/wrappers/gltrace_arrays.cpp
Examining data/apitrace-9.0+repack/wrappers/gltrace_arrays.hpp
Examining data/apitrace-9.0+repack/wrappers/gltrace_state.cpp
Examining data/apitrace-9.0+repack/wrappers/memtrace.cpp
Examining data/apitrace-9.0+repack/wrappers/memtrace.hpp
Examining data/apitrace-9.0+repack/wrappers/stub.cpp

FINAL RESULTS:

data/apitrace-9.0+repack/inject/injector.cpp:574:13:  [5] (misc) SetSecurityDescriptorDacl:
  Never create NULL ACLs; an attacker can set it to Everyone (Deny All
  Access), which would even forbid administrator access (CWE-732).
            SetSecurityDescriptorDacl(&sd, TRUE, NULL, FALSE))
data/apitrace-9.0+repack/inject/injector.cpp:574:13:  [5] (misc) SetSecurityDescriptorDacl:
  Never create NULL ACLs; an attacker can set it to Everyone (Deny All
  Access), which would even forbid administrator access (CWE-732).
            SetSecurityDescriptorDacl(&sd, TRUE, NULL, FALSE))
data/apitrace-9.0+repack/lib/os/os_posix.cpp:104:11:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
    len = readlink("/proc/self/exe", buf, size - 1);
data/apitrace-9.0+repack/retrace/process_name.cpp:52:1:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
readlink(const char *pathname, char *buf, size_t bufsiz)
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:50:9:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
#define chmod(F, P) (0)
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:51:9:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
#define chown(F, O, G) (0)
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:645:9:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
  res = chmod(output_path, statbuf.st_mode & (S_IRWXU | S_IRWXG | S_IRWXO));
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:650:9:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
  res = chown(output_path, (uid_t)-1, statbuf.st_gid);
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:655:9:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
  res = chown(output_path, statbuf.st_uid, (gid_t)-1);
data/apitrace-9.0+repack/cli/cli_pager.cpp:137:9:  [4] (shell) execlp:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
        execlp(pager, pager, NULL);
data/apitrace-9.0+repack/dispatch/glproc_gl.cpp:108:13:  [4] (tmpfile) mktemp:
  Temporary file race condition (CWE-377).
        if (mktemp(temp_filename) != NULL) {
data/apitrace-9.0+repack/gui/calldurationgraph.h:159:64:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
            text += QString("\nPixels Drawn: %1").arg(QLocale::system().toString((qlonglong)call.pixels));
data/apitrace-9.0+repack/gui/profileheatmap.h:425:64:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
            text += QString("\nPixels Drawn: %1").arg(QLocale::system().toString((qlonglong)call.pixels));
data/apitrace-9.0+repack/gui/profiletablemodel.cpp:236:29:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
            return QLocale::system().toString(row.uses);
data/apitrace-9.0+repack/gui/profiletablemodel.cpp:242:29:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
            return QLocale::system().toString((qlonglong)row.pixels);
data/apitrace-9.0+repack/gui/profiletablemodel.cpp:248:29:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
            return QLocale::system().toString((row.uses <= 0) ? 0 : (row.pixels / row.uses));
data/apitrace-9.0+repack/gui/profiling.h:54:36:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
        if (text.endsWith(QLocale::system().decimalPoint()))
data/apitrace-9.0+repack/gui/saverthread.cpp:252:9:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
        strcpy(newString, ba.constData());
data/apitrace-9.0+repack/inject/inject.h:48:29:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__ ((format (printf, 1, 2)))
data/apitrace-9.0+repack/inject/injector.cpp:73:5:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vfprintf(stderr, format, ap);
data/apitrace-9.0+repack/inject/injector.cpp:286:5:  [4] (format) _snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
    _snprintf(szDebuggerCommand, sizeof szDebuggerCommand, szDebugger,
data/apitrace-9.0+repack/lib/os/os.hpp:38:9:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#ifndef snprintf
data/apitrace-9.0+repack/lib/os/os.hpp:39:9:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#define snprintf _snprintf
data/apitrace-9.0+repack/lib/os/os.hpp:39:18:  [4] (format) _snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#define snprintf _snprintf
data/apitrace-9.0+repack/lib/os/os.hpp:41:9:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#ifndef vsnprintf
data/apitrace-9.0+repack/lib/os/os.hpp:42:9:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#define vsnprintf _vsnprintf
data/apitrace-9.0+repack/lib/os/os.hpp:55:29:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__ ((format (printf, 1, 2)))
data/apitrace-9.0+repack/lib/os/os_posix.cpp:126:9:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
        strcpy(buf, program_invocation_name);
data/apitrace-9.0+repack/lib/os/os_posix.cpp:224:9:  [4] (shell) execvp:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
        execvp(args[0], args);
data/apitrace-9.0+repack/lib/os/os_posix.cpp:273:5:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vfprintf(log, format, ap);
data/apitrace-9.0+repack/lib/os/os_string.hpp:208:29:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__ ((format (printf, 1, 2)))
data/apitrace-9.0+repack/lib/os/os_string.hpp:226:18:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        length = vsnprintf(&dummy, sizeof dummy, format, args_copy);
data/apitrace-9.0+repack/lib/os/os_string.hpp:236:9:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        vsnprintf(path.buf(), size, format, args);
data/apitrace-9.0+repack/lib/os/os_win32.cpp:233:5:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
    vsnprintf(buf, sizeof buf, format, ap);
data/apitrace-9.0+repack/thirdparty/brotli/c/common/platform.h:470:23:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#define BROTLI_LOG(x) printf x
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:706:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
  strcpy(context->modified_path, arg);
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:730:5:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
    strcpy(context->modified_path + arg_len, context->suffix);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:536:69:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(APIENTRYP PFNGLMAPBUFFERPROC) (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:556:57:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void *APIENTRY glMapBuffer (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:1199:114:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(APIENTRYP PFNGLMAPBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:1284:102:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void *APIENTRY glMapBufferRange (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:2144:134:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void (APIENTRYP PFNGLBINDIMAGETEXTUREPROC) (GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:2157:122:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void APIENTRY glBindImageTexture (GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:2600:74:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(APIENTRYP PFNGLMAPNAMEDBUFFERPROC) (GLuint buffer, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:2601:119:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(APIENTRYP PFNGLMAPNAMEDBUFFERRANGEPROC) (GLuint buffer, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:2723:62:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void *APIENTRY glMapNamedBuffer (GLuint buffer, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:2724:107:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void *APIENTRY glMapNamedBufferRange (GLuint buffer, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:2910:87:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void (APIENTRYP PFNGLMAKEIMAGEHANDLERESIDENTARBPROC) (GLuint64 handle, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:2927:75:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void APIENTRY glMakeImageHandleResidentARB (GLuint64 handle, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:4739:72:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(APIENTRYP PFNGLMAPBUFFERARBPROC) (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:4751:60:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void *APIENTRY glMapBufferARB (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:6901:77:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(APIENTRYP PFNGLMAPNAMEDBUFFEREXTPROC) (GLuint buffer, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:7013:122:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(APIENTRYP PFNGLMAPNAMEDBUFFERRANGEEXTPROC) (GLuint buffer, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:7157:65:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void *APIENTRY glMapNamedBufferEXT (GLuint buffer, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:7269:110:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void *APIENTRY glMapNamedBufferRangeEXT (GLuint buffer, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:8172:138:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void (APIENTRYP PFNGLBINDIMAGETEXTUREEXTPROC) (GLuint index, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLint format);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:8175:126:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void APIENTRY glBindImageTextureEXT (GLuint index, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLint format);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:9199:95:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(APIENTRYP PFNGLMAPTEXTURE2DINTELPROC) (GLuint texture, GLint level, GLbitfield access, GLint *stride, GLenum *layout);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:9203:83:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void *APIENTRY glMapTexture2DINTEL (GLuint texture, GLint level, GLbitfield access, GLint *stride, GLenum *layout);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:9492:86:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void (APIENTRYP PFNGLMAKEIMAGEHANDLERESIDENTNVPROC) (GLuint64 handle, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:9506:74:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void APIENTRY glMakeImageHandleResidentNV (GLuint64 handle, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:10961:79:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void (APIENTRYP PFNGLMAKEBUFFERRESIDENTNVPROC) (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:10964:84:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void (APIENTRYP PFNGLMAKENAMEDBUFFERRESIDENTNVPROC) (GLuint buffer, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:10975:67:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void APIENTRY glMakeBufferResidentNV (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:10978:72:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void APIENTRY glMakeNamedBufferResidentNV (GLuint buffer, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:11354:90:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void (APIENTRYP PFNGLVDPAUSURFACEACCESSNVPROC) (GLvdpauSurfaceNV surface, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glext.h:11365:78:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GLAPI void APIENTRY glVDPAUSurfaceAccessNV (GLvdpauSurfaceNV surface, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/wglext.h:641:122:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef HANDLE (WINAPI * PFNWGLDXREGISTEROBJECTNVPROC) (HANDLE hDevice, void *dxObject, GLuint name, GLenum type, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/wglext.h:643:76:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef BOOL (WINAPI * PFNWGLDXOBJECTACCESSNVPROC) (HANDLE hObject, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/wglext.h:650:103:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
HANDLE WINAPI wglDXRegisterObjectNV (HANDLE hDevice, void *dxObject, GLuint name, GLenum type, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GL/wglext.h:652:57:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
BOOL WINAPI wglDXObjectAccessNV (HANDLE hObject, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES/glext.h:334:75:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(GL_APIENTRYP PFNGLMAPBUFFEROESPROC) (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES/glext.h:338:64:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GL_API void *GL_APIENTRY glMapBufferOES (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES/glext.h:649:120:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(GL_APIENTRYP PFNGLMAPBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES/glext.h:652:109:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GL_API void *GL_APIENTRY glMapBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2ext.h:442:75:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(GL_APIENTRYP PFNGLMAPBUFFEROESPROC) (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2ext.h:446:68:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GL_APICALL void *GL_APIENTRY glMapBufferOES (GLenum target, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2ext.h:1493:120:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void *(GL_APIENTRYP PFNGLMAPBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2ext.h:1496:113:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GL_APICALL void *GL_APIENTRY glMapBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2ext.h:2486:89:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
typedef void (GL_APIENTRYP PFNGLMAKEIMAGEHANDLERESIDENTNVPROC) (GLuint64 handle, GLenum access);
data/apitrace-9.0+repack/thirdparty/khronos/GLES2/gl2ext.h:2500:82:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
GL_APICALL void GL_APIENTRY glMakeImageHandleResidentNV (GLuint64 handle, GLenum access);
data/apitrace-9.0+repack/cli/cli_dump.cpp:165:19:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((opt = getopt_long(argc, argv, shortOptions, longOptions, NULL)) != -1) {
data/apitrace-9.0+repack/cli/cli_dump_images.cpp:90:19:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((opt = getopt_long(argc, argv, shortOptions, longOptions, NULL)) != -1) {
data/apitrace-9.0+repack/cli/cli_pager.cpp:128:17:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
        pager = getenv("PAGER");
data/apitrace-9.0+repack/cli/cli_pager.cpp:133:14:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
        if (!getenv("PAGER")) {
data/apitrace-9.0+repack/cli/cli_pickle.cpp:245:19:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((opt = getopt_long(argc, argv, shortOptions, longOptions, NULL)) != -1) {
data/apitrace-9.0+repack/cli/cli_repack.cpp:224:19:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((opt = getopt_long(argc, argv, shortOptions, longOptions, NULL)) != -1) {
data/apitrace-9.0+repack/cli/cli_sed.cpp:366:19:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((opt = getopt_long(argc, argv, shortOptions, longOptions, NULL)) != -1) {
data/apitrace-9.0+repack/cli/cli_trace.cpp:196:38:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
        const char *oldEnvVarValue = getenv(TRACE_VARIABLE);
data/apitrace-9.0+repack/cli/cli_trace.cpp:378:19:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((opt = getopt_long(argc, argv, shortOptions, longOptions, NULL)) != -1) {
data/apitrace-9.0+repack/cli/cli_trim.cpp:173:19:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((opt = getopt_long(argc, argv, shortOptions, longOptions, NULL)) != -1) {
data/apitrace-9.0+repack/dispatch/glproc_gl.cpp:180:39:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
        const char * libgl_filename = getenv("TRACE_LIBGL");
data/apitrace-9.0+repack/inject/injectee_iat.cpp:419:5:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
    EnterCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_iat.cpp:682:9:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
        EnterCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_iat.cpp:1027:5:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
    EnterCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_iat.cpp:1116:9:  [3] (misc) InitializeCriticalSection:
  Exceptions can be thrown in low-memory situations. Use
  InitializeCriticalSectionAndSpinCount instead.
        InitializeCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_iat.cpp:1131:28:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
            szNewDllName = getenv("INJECT_DLL");
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:395:9:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
        EnterCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:452:13:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
            EnterCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:639:17:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
                EnterCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:691:5:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
    EnterCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:739:9:  [3] (misc) InitializeCriticalSection:
  Exceptions can be thrown in low-memory situations. Use
  InitializeCriticalSectionAndSpinCount instead.
        InitializeCriticalSection(&g_Mutex);
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:754:28:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
            szNewDllName = getenv("INJECT_DLL");
data/apitrace-9.0+repack/lib/highlight/highlight.cpp:261:32:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
            const char *term = getenv("TERM");
data/apitrace-9.0+repack/lib/os/os.hpp:99:1:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
random(void) {
data/apitrace-9.0+repack/lib/os/os.hpp:103:14:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    return ::random();
data/apitrace-9.0+repack/lib/os/os_backtrace.cpp:103:18:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    char *list = getenv("APITRACE_BACKTRACE");
data/apitrace-9.0+repack/lib/os/os_posix.cpp:167:27:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    const char *homeDir = getenv("HOME");
data/apitrace-9.0+repack/lib/os/os_posix.cpp:175:33:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    const char *configHomeDir = getenv("XDG_CONFIG_HOME");
data/apitrace-9.0+repack/lib/os/os_posix.cpp:179:31:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
        const char *homeDir = getenv("HOME");
data/apitrace-9.0+repack/lib/os/os_thread.hpp:114:13:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
            EnterCriticalSection(&_native_handle);
data/apitrace-9.0+repack/lib/os/os_thread.hpp:147:13:  [3] (misc) InitializeCriticalSection:
  Exceptions can be thrown in low-memory situations. Use
  InitializeCriticalSectionAndSpinCount instead.
            InitializeCriticalSection(&_native_handle);
data/apitrace-9.0+repack/lib/os/os_thread.hpp:164:13:  [3] (misc) InitializeCriticalSection:
  Exceptions can be thrown in low-memory situations. Use
  InitializeCriticalSectionAndSpinCount instead.
            InitializeCriticalSection(&_native_handle);
data/apitrace-9.0+repack/lib/os/os_thread.hpp:312:13:  [3] (misc) EnterCriticalSection:
  On some versions of Windows, exceptions can be thrown in low-memory
  situations. Use InitializeCriticalSectionAndSpinCount instead.
            EnterCriticalSection(&mutex_native_handle);
data/apitrace-9.0+repack/lib/trace/trace_fast_callset.cpp:82:25:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    long int bits = os::random() | os::random();
data/apitrace-9.0+repack/lib/trace/trace_fast_callset.cpp:82:40:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    long int bits = os::random() | os::random();
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:95:18:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    lpFileName = getenv("TRACE_FILE");
data/apitrace-9.0+repack/retrace/glws_waffle.cpp:136:40:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    const char *waffle_platform_name = getenv("WAFFLE_PLATFORM");
data/apitrace-9.0+repack/retrace/glws_wgl.cpp:411:35:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    const char * libgl_filename = getenv("TRACE_LIBGL");
data/apitrace-9.0+repack/wrappers/config.cpp:368:37:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
        const char *envConfigPath = getenv("GLTRACE_CONF");
data/apitrace-9.0+repack/wrappers/dlltrace.hpp:57:40:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
            const char* pathOverride = getenv("APITRACE_FORCE_MODULE_PATH");
data/apitrace-9.0+repack/wrappers/dlsym.cpp:172:39:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
        const char * libgl_filename = getenv("TRACE_LIBGL");
data/apitrace-9.0+repack/cli/cli_diff.cpp:49:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char *args[4];
data/apitrace-9.0+repack/cli/cli_diff_images.cpp:49:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char *args[4];
data/apitrace-9.0+repack/cli/cli_diff_state.cpp:49:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char *args[4];
data/apitrace-9.0+repack/cli/cli_dump.cpp:255:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        if (!p.open(argv[i])) {
data/apitrace-9.0+repack/cli/cli_leaks.cpp:49:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char *args[4];
data/apitrace-9.0+repack/cli/cli_pickle.cpp:273:21:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        if (!parser.open(argv[i])) {
data/apitrace-9.0+repack/cli/cli_repack.cpp:118:18:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    FILE *fout = fopen(outFileName, "wb");
data/apitrace-9.0+repack/cli/cli_repack.cpp:169:21:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!outFileIn->open(outFileName)) {
data/apitrace-9.0+repack/cli/cli_repack.cpp:232:27:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
                quality = atoi(optarg);
data/apitrace-9.0+repack/cli/cli_retrace.cpp:48:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!p.open(filename)) {
data/apitrace-9.0+repack/cli/cli_sed.cpp:140:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(str, replaceString.c_str(), len);
data/apitrace-9.0+repack/cli/cli_sed.cpp:237:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!p.open(inFileName)) {
data/apitrace-9.0+repack/cli/cli_sed.cpp:256:17:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!writer.open(outFileName.c_str(), p.getVersion(), properties)) {
data/apitrace-9.0+repack/cli/cli_sed.cpp:334:23:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
            FILE *f = fopen(fname.c_str(), "rt");
data/apitrace-9.0+repack/cli/cli_sed.cpp:339:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char buf[1024];
data/apitrace-9.0+repack/cli/cli_trace.cpp:226:32:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
                int scriptFD = mkstemp(scriptFileName);
data/apitrace-9.0+repack/cli/cli_trim.cpp:103:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!p.open(filename)) {
data/apitrace-9.0+repack/cli/cli_trim.cpp:117:17:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!writer.open(options->output.c_str(), p.getVersion(), p.getProperties())) {
data/apitrace-9.0+repack/cli/cli_trim.cpp:185:38:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            options.threadIds.insert(atoi(optarg));
data/apitrace-9.0+repack/cli/pickle.hpp:302:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char c[8];
data/apitrace-9.0+repack/dispatch/glproc_gl.cpp:55:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char szDll[MAX_PATH] = {0};
data/apitrace-9.0+repack/dispatch/glproc_gl.cpp:61:9:  [2] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant string.
        strcat(szDll, "\\opengl32.dll");
data/apitrace-9.0+repack/gui/apisurface.cpp:186:26:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                unsigned char rgba[4] = {0, 0, 0, 0xff};
data/apitrace-9.0+repack/gui/apisurface.cpp:204:26:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                unsigned char rgba[4] = {0, 0, 0, 0xff};
data/apitrace-9.0+repack/gui/apitracemodel.cpp:82:28:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
                    buffer.open(QIODevice::WriteOnly);
data/apitrace-9.0+repack/gui/glsledit.cpp:967:15:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!file.open()) {
data/apitrace-9.0+repack/gui/mainwindow.cpp:1602:15:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!file.open(QIODevice::WriteOnly)) {
data/apitrace-9.0+repack/gui/qubjson_test.cpp:50:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    buffer.open(QIODevice::ReadOnly);
data/apitrace-9.0+repack/gui/retracer.cpp:455:17:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                char header[512];
data/apitrace-9.0+repack/gui/retracer.cpp:504:17:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                char line[256];
data/apitrace-9.0+repack/gui/saverthread.cpp:360:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    parser.open(m_readFileName.toLocal8Bit());
data/apitrace-9.0+repack/gui/saverthread.cpp:363:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    writer.open(m_writeFileName.toLocal8Bit(), parser.getVersion(), parser.getProperties());
data/apitrace-9.0+repack/gui/traceloader.cpp:53:19:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!m_parser.open(filename.toLatin1())) {
data/apitrace-9.0+repack/gui/traceloader.cpp:98:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (file.open(QIODevice::ReadOnly | QIODevice::Text)) {
data/apitrace-9.0+repack/helpers/d3dshader.cpp:68:21:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                    char filename[256];
data/apitrace-9.0+repack/helpers/d3dshader.cpp:142:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char szFilename[MAX_PATH];
data/apitrace-9.0+repack/helpers/d3dshader.cpp:163:17:  [2] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant string.
                strcat(szFilename, "\\d3d10.dll");
data/apitrace-9.0+repack/inject/inject.h:139:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char szDllName[4096 - sizeof(BOOL)];
data/apitrace-9.0+repack/inject/injectee_iat.cpp:74:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char buf[512];
data/apitrace-9.0+repack/inject/injectee_iat.cpp:133:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char szDllPath[MAX_PATH];
data/apitrace-9.0+repack/inject/injectee_iat.cpp:804:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char szCaller[MAX_PATH];
data/apitrace-9.0+repack/inject/injectee_iat.cpp:942:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char szModule[MAX_PATH];
data/apitrace-9.0+repack/inject/injectee_iat.cpp:1145:20:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            static char szSharedMemCopy[MAX_PATH];
data/apitrace-9.0+repack/inject/injectee_iat.cpp:1157:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char szProcess[MAX_PATH];
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:128:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char buf[512];
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:171:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char szDllPath[MAX_PATH];
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:600:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char szCaller[MAX_PATH];
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:768:20:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            static char szSharedMemCopy[MAX_PATH];
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:780:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char szProcess[MAX_PATH];
data/apitrace-9.0+repack/inject/injector.cpp:267:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char szDebugger[1024];
data/apitrace-9.0+repack/inject/injector.cpp:285:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char szDebuggerCommand[1024];
data/apitrace-9.0+repack/inject/injector.cpp:407:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char szModName[MAX_PATH];
data/apitrace-9.0+repack/inject/injector.cpp:530:27:  [2] (integer) atol:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            dwProcessId = atol(argv[optind]);
data/apitrace-9.0+repack/inject/injector.cpp:637:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char szProcess[MAX_PATH];
data/apitrace-9.0+repack/inject/injector.cpp:710:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char szDllPath[MAX_PATH];
data/apitrace-9.0+repack/lib/image/image_md5.cpp:47:14:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    unsigned char signature[16];
data/apitrace-9.0+repack/lib/image/image_md5.cpp:51:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char csig[33];
data/apitrace-9.0+repack/lib/image/image_pnm.cpp:310:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(row, headerEnd, rowBytes);
data/apitrace-9.0+repack/lib/os/os_backtrace.cpp:254:41:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
                stackFrame.linenumber = atoi(linenumber);
data/apitrace-9.0+repack/lib/os/os_backtrace.cpp:306:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char buf[sizeof(long long) * 2], *p;
data/apitrace-9.0+repack/lib/os/os_posix.cpp:110:18:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        int fd = open("/proc/self/cmdline", O_RDONLY);
data/apitrace-9.0+repack/lib/os/os_posix.cpp:437:1:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
char statmBuff[256];
data/apitrace-9.0+repack/lib/os/os_posix.cpp:444:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    int fd = open("/proc/self/statm", O_RDONLY, 0);
data/apitrace-9.0+repack/lib/os/os_win32.cpp:228:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char buf[4096];
data/apitrace-9.0+repack/lib/trace/trace_callset.cpp:204:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        stream.open(filename);
data/apitrace-9.0+repack/lib/trace/trace_file.hpp:57:10:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    bool open(const char *filename);
data/apitrace-9.0+repack/lib/trace/trace_file.hpp:84:19:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
inline bool File::open(const char *filename)
data/apitrace-9.0+repack/lib/trace/trace_file_brotli.cpp:82:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    m_stream.open(filename, fmode);
data/apitrace-9.0+repack/lib/trace/trace_file_read.cpp:63:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!file->open(filename)) {
data/apitrace-9.0+repack/lib/trace/trace_file_snappy.cpp:150:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    m_stream.open(filename, fmode);
data/apitrace-9.0+repack/lib/trace/trace_file_snappy.cpp:176:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(buffer, m_cachePtr, length);
data/apitrace-9.0+repack/lib/trace/trace_file_snappy.cpp:184:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy((char*)buffer + offset, m_cachePtr, chunkSize);
data/apitrace-9.0+repack/lib/trace/trace_file_snappy.cpp:278:14:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    unsigned char buf[4];
data/apitrace-9.0+repack/lib/trace/trace_file_zlib.cpp:91:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    fd = ::open(filename, flags, 0666);
data/apitrace-9.0+repack/lib/trace/trace_option.cpp:59:12:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
    return atoi(option);
data/apitrace-9.0+repack/lib/trace/trace_ostream_snappy.cpp:107:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    m_stream.open(filename, fmode);
data/apitrace-9.0+repack/lib/trace/trace_ostream_snappy.cpp:125:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(m_cachePtr, buffer, length);
data/apitrace-9.0+repack/lib/trace/trace_ostream_snappy.cpp:128:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(m_cachePtr, buffer, length);
data/apitrace-9.0+repack/lib/trace/trace_ostream_snappy.cpp:137:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(m_cachePtr, (const char*)buffer + offset, endSize);
data/apitrace-9.0+repack/lib/trace/trace_ostream_snappy.cpp:144:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(m_cachePtr, (const char*)buffer + offset, sizeToWrite);
data/apitrace-9.0+repack/lib/trace/trace_ostream_snappy.cpp:186:14:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    unsigned char buf[4];
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:54:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
bool Parser::open(const char *filename) {
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:259:44:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        const char **arg_names = new const char *[sig->num_args];
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:328:47:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        const char **member_names = new const char *[sig->num_members];
data/apitrace-9.0+repack/lib/trace/trace_parser.hpp:56:18:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    virtual bool open(const char *filename) = 0;
data/apitrace-9.0+repack/lib/trace/trace_parser.hpp:129:10:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    bool open(const char *filename) override;
data/apitrace-9.0+repack/lib/trace/trace_parser_loop.cpp:50:10:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    bool open(const char *filename) override;
data/apitrace-9.0+repack/lib/trace/trace_parser_loop.cpp:63:22:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
LastFrameLoopParser::open(const char *filename)
data/apitrace-9.0+repack/lib/trace/trace_parser_loop.cpp:65:24:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    bool ret = parser->open(filename);
data/apitrace-9.0+repack/lib/trace/trace_writer.cpp:61:9:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
Writer::open(const char *filename,
data/apitrace-9.0+repack/lib/trace/trace_writer.cpp:105:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char buf[2 * sizeof value];
data/apitrace-9.0+repack/lib/trace/trace_writer.hpp:57:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        bool open(const char *filename,
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:50:14:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static const char *memcpy_args[3] = {"dest", "src", "n"};
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:53:14:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static const char *malloc_args[1] = {"size"};
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:56:14:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static const char *free_args[1] = {"ptr"};
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:59:14:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static const char *realloc_args[2] = {"ptr", "size"};
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:90:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
LocalWriter::open(void) {
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:113:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char szDesktopPath[MAX_PATH];
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:131:20:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
            file = fopen(lpFileName, "rb");
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:147:18:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    if (!Writer::open(lpFileName, TRACE_VERSION, properties)) {
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:174:9:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        open();
data/apitrace-9.0+repack/lib/trace/trace_writer_local.cpp:184:9:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        open();
data/apitrace-9.0+repack/lib/trace/trace_writer_local.hpp:88:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        void open(void);
data/apitrace-9.0+repack/retrace/d3d10state_images.cpp:431:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char label[64];
data/apitrace-9.0+repack/retrace/d3d10state_images.cpp:631:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char label[64];
data/apitrace-9.0+repack/retrace/d3d11state.cpp:272:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char label[64];
data/apitrace-9.0+repack/retrace/d3d11state.cpp:294:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char label[64];
data/apitrace-9.0+repack/retrace/d3d11state_images.cpp:414:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char label[64];
data/apitrace-9.0+repack/retrace/d3d11state_images.cpp:689:17:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                char label[64];
data/apitrace-9.0+repack/retrace/d3d11state_images.cpp:735:17:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                char label[64];
data/apitrace-9.0+repack/retrace/d3d11state_images.cpp:762:17:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                char label[64];
data/apitrace-9.0+repack/retrace/d3d8state_images.cpp:198:21:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                    char label[128];
data/apitrace-9.0+repack/retrace/d3d9state_formats.cpp:400:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(dst, src, Width * sizeof(float));
data/apitrace-9.0+repack/retrace/d3d9state_images.cpp:465:21:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                    char label[128];
data/apitrace-9.0+repack/retrace/d3d9state_images.cpp:508:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char label[64];
data/apitrace-9.0+repack/retrace/glstate_images.cpp:485:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char logInfo[1000];
data/apitrace-9.0+repack/retrace/glstate_images.cpp:510:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char logInfo[1000];
data/apitrace-9.0+repack/retrace/glstate_shaders.cpp:144:32:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
                    FILE *fp = fopen("program.bin", "wb");
data/apitrace-9.0+repack/retrace/glstate_shaders.cpp:824:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char name[256];
data/apitrace-9.0+repack/retrace/glstate_shaders.cpp:847:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char name[256];
data/apitrace-9.0+repack/retrace/glws_xlib.cpp:78:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char buffer[32];
data/apitrace-9.0+repack/retrace/glws_xlib.cpp:93:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char buffer[512];
data/apitrace-9.0+repack/retrace/json.cpp:142:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char buf[4];
data/apitrace-9.0+repack/retrace/metric_backend_intel_perfquery.cpp:44:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char name[INTEL_NAME_LENGTH];
data/apitrace-9.0+repack/retrace/metric_backend_intel_perfquery.cpp:66:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char desc[INTEL_DESC_LENGTH];
data/apitrace-9.0+repack/retrace/metric_backend_intel_perfquery.cpp:202:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char name[INTEL_NAME_LENGTH];
data/apitrace-9.0+repack/retrace/mmap_allocator.hpp:81:14:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
        fd = mkstemp(templ);
data/apitrace-9.0+repack/retrace/process_name.cpp:69:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(buf, g_processName.data(), len);
data/apitrace-9.0+repack/retrace/process_name.cpp:73:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(buf, g_processName.data(), bufsiz);
data/apitrace-9.0+repack/retrace/process_name.cpp:155:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char szCaller[MAX_PATH];
data/apitrace-9.0+repack/retrace/process_name.cpp:167:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(lpFilename, g_processName.data(), len);
data/apitrace-9.0+repack/retrace/process_name.cpp:172:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(lpFilename, g_processName.data(), nSize - 1);
data/apitrace-9.0+repack/retrace/retrace.cpp:78:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char szErrorDesc[512];
data/apitrace-9.0+repack/retrace/retrace_main.cpp:207:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char comment[21];
data/apitrace-9.0+repack/retrace/retrace_main.cpp:997:31:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            dumpStateCallNo = atoi(optarg);
data/apitrace-9.0+repack/retrace/retrace_main.cpp:1019:32:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            retrace::samples = atoi(optarg);
data/apitrace-9.0+repack/retrace/retrace_main.cpp:1112:32:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            snapshotInterval = atoi(optarg);
data/apitrace-9.0+repack/retrace/retrace_main.cpp:1190:35:  [2] (integer) atol:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            retrace::minCpuTime = atol(optarg);
data/apitrace-9.0+repack/retrace/retrace_main.cpp:1241:26:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
            if (!parser->open(argv[i])) {
data/apitrace-9.0+repack/retrace/retrace_stdc.cpp:88:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy((char *)destRange.ptr + destOffset,
data/apitrace-9.0+repack/retrace/retrace_stdc.cpp:97:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy((char *)destRange.ptr + destOffset,
data/apitrace-9.0+repack/retrace/retrace_stdc.cpp:116:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(destRange.ptr, srcRange.ptr, n);
data/apitrace-9.0+repack/thirdparty/brotli/c/common/platform.h:293:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(&t, p, sizeof t);
data/apitrace-9.0+repack/thirdparty/brotli/c/common/platform.h:298:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(&t, p, sizeof t);
data/apitrace-9.0+repack/thirdparty/brotli/c/common/platform.h:303:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(&t, p, sizeof t);
data/apitrace-9.0+repack/thirdparty/brotli/c/common/platform.h:307:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(p, &v, sizeof v);
data/apitrace-9.0+repack/thirdparty/brotli/c/common/platform.h:368:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(&v, p, sizeof(uint64_t));
data/apitrace-9.0+repack/thirdparty/brotli/c/common/platform.h:373:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(p, &v, sizeof(uint64_t));
data/apitrace-9.0+repack/thirdparty/brotli/c/common/transform.c:14:14:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static const char kPrefixSuffix[217] =
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/bit_reader.h:300:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(dest, br->next_in, num);
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c:174:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(buffer, src, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c:175:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(dst, buffer, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c:925:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(&pattern, &b0123, 4);
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c:1274:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(*next_out, start, num_written);
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c:1304:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(s->ringbuffer, s->ringbuffer_end, (size_t)s->pos);
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c:1334:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(s->ringbuffer, old_ringbuffer, (size_t)s->pos);
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c:1830:11:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
          memcpy(&s->ringbuffer[pos], word, (size_t)len);
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/decode.c:1883:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(copy_dst + 16, copy_src + 16, (size_t)(i - 16));
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/huffman.c:225:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&table[table_size], &table[0],
data/apitrace-9.0+repack/thirdparty/brotli/c/dec/huffman.c:330:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&table[table_size], &table[0],
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/backward_references_hq.c:791:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(orig_dist_cache, dist_cache, 4 * sizeof(dist_cache[0]));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/backward_references_hq.c:810:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(dist_cache, orig_dist_cache, 4 * sizeof(dist_cache[0]));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/block_splitter.c:63:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(literals + pos, data + from_pos, head_size);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/block_splitter.c:69:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(literals + pos, data + from_pos, insert_len);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/brotli_bit_stream.c:1308:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&storage[*storage_ix >> 3], &input[masked_pos], len1);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/brotli_bit_stream.c:1313:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(&storage[*storage_ix >> 3], &input[masked_pos], len);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:142:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth, depth, 24);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:143:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 24, depth + 40, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:144:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 32, depth + 24, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:145:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 40, depth + 48, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:146:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 48, depth + 32, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:147:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 56, depth + 56, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:149:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits, cmd_bits, 48);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:150:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 24, cmd_bits + 32, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:151:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 32, cmd_bits + 48, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:152:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 40, cmd_bits + 24, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:153:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 48, cmd_bits + 40, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:154:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 56, cmd_bits + 56, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:160:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth, depth, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:161:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth + 64, depth + 8, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:162:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth + 128, depth + 16, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:163:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth + 192, depth + 24, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:164:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth + 384, depth + 32, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:411:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(&storage[*storage_ix >> 3], begin, len);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment.c:487:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_histo, kCmdHistoSeed, sizeof(kCmdHistoSeed));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:84:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth, depth + 24, 24);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:85:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 24, depth, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:86:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 32, depth + 48, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:87:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 40, depth + 8, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:88:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 48, depth + 56, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:89:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(cmd_depth + 56, depth + 16, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:91:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits, cmd_bits + 24, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:92:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 8, cmd_bits + 40, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:93:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 16, cmd_bits + 56, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:94:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 24, cmd_bits, 48);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:95:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 48, cmd_bits + 32, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:96:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(bits + 56, cmd_bits + 48, 16);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:102:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth, depth + 24, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:103:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth + 64, depth + 32, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:104:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth + 128, depth + 40, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:105:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth + 192, depth + 48, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:106:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(cmd_depth + 384, depth + 56, 8);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:333:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(*literals, next_emit, (size_t)insert);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:450:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(*literals, next_emit, insert);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/compress_fragment_two_pass.c:552:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(&storage[*storage_ix >> 3], input, input_size);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:41:30:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
#define COPY_ARRAY(dst, src) memcpy(dst, src, sizeof(src));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:570:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(dist_cache, saved_dist_cache, 4 * sizeof(dist_cache[0]));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:639:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(dist_cache, saved_dist_cache, 4 * sizeof(dist_cache[0]));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1014:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(new_commands, s->commands_, sizeof(Command) * s->num_commands_);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1260:11:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
          memcpy(new_commands, commands, sizeof(Command) * num_commands);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1298:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(dist_cache, saved_dist_cache, 4 * sizeof(dist_cache[0]));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1342:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(dist_cache, saved_dist_cache, 4 * sizeof(dist_cache[0]));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1361:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(saved_dist_cache, dist_cache, 4 * sizeof(dist_cache[0]));
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1367:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(encoded_buffer, storage, out_size);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1422:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&output[result], &input[offset], chunk_size);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1536:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(*next_out, s->next_out_, copy_output_size);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1718:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(*next_out, *next_in, copy);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/encode.c:1728:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(s->next_out_, *next_in, copy);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/memory.c:129:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(m->pointers + PERM_ALLOCATED_OFFSET + m->perm_allocated,
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/memory.h:76:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(new_array, A, C * sizeof(T));       \
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/ringbuffer.h:80:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(new_data, rb->data_,
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/ringbuffer.h:99:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&rb->buffer_[p], bytes,
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/ringbuffer.h:117:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(rb->buffer_, bytes, n);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/ringbuffer.h:136:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(&rb->buffer_[masked_pos], bytes, n);
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/ringbuffer.h:140:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(&rb->buffer_[masked_pos], bytes,
data/apitrace-9.0+repack/thirdparty/brotli/c/enc/ringbuffer.h:143:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(&rb->buffer_[0], bytes + (rb->size_ - masked_pos),
data/apitrace-9.0+repack/thirdparty/brotli/c/fuzz/run_decode_fuzzer.c:22:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
  FILE* f = fopen(argv[1], "r");
data/apitrace-9.0+repack/thirdparty/brotli/c/fuzz/run_decode_fuzzer.c:38:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
  memcpy(data, tmp, len);
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:47:9:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
#define fopen ms_fopen
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:48:9:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
#define open ms_open
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:579:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
  *f = fopen(input_path, "rb");
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:596:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
  fd = open(output_path, O_CREAT | (force ? 0 : O_EXCL) | O_WRONLY | O_TRUNC,
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:613:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
  FILE* f = fopen(path, "rb");
data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h:778:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char    pipeName[80]; /* Should be [GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX] */
data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h:782:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char    pipeName[80]; /* Should be [GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX] */
data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h:788:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char pipeName[80]; /* Should be [GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX] */
data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h:793:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char pipeName[80]; /* Should be [GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX] */
data/apitrace-9.0+repack/wrappers/config.cpp:100:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(conf->extensionsList[count], extStart, extLen);
data/apitrace-9.0+repack/wrappers/config.cpp:123:8:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static char buffer[10*1000];
data/apitrace-9.0+repack/wrappers/config.cpp:207:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char valBuf[100];
data/apitrace-9.0+repack/wrappers/config.cpp:232:12:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
    return atoi(valBuf);
data/apitrace-9.0+repack/wrappers/config.cpp:329:15:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    FILE *f = fopen(filename, "r");
data/apitrace-9.0+repack/wrappers/dlltrace.hpp:56:13:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
            char szSystemDir[MAX_PATH] = {0};
data/apitrace-9.0+repack/wrappers/glcaps.cpp:149:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(newExtensions, extensions, extensionsLen);
data/apitrace-9.0+repack/wrappers/glcaps.cpp:160:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(newExtensions + extensionsLen, extraExtension, extraExtensionLen);
data/apitrace-9.0+repack/wrappers/glmemshadow.cpp:208:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(shadowMemory, data, size);
data/apitrace-9.0+repack/wrappers/glmemshadow.cpp:245:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(shadowMemory + start, glMemory, size);
data/apitrace-9.0+repack/wrappers/glmemshadow.cpp:358:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(glMemory + glOffset, shadowSlice + shadowOffset, size);
data/apitrace-9.0+repack/wrappers/glmemshadow.cpp:363:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(glMemory, shadowSlice + glStartOffset, size);
data/apitrace-9.0+repack/wrappers/glmemshadow.cpp:382:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(shadowMemory + mappedStart, glMemory, mappedSize);
data/apitrace-9.0+repack/cli/cli_main.cpp:118:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (strlen(command->name) > max_width) {
data/apitrace-9.0+repack/cli/cli_main.cpp:119:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
            max_width = strlen(command->name);
data/apitrace-9.0+repack/cli/cli_pager.cpp:100:17:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
            int read;
data/apitrace-9.0+repack/cli/cli_pager.cpp:118:18:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        close(fd.read);
data/apitrace-9.0+repack/cli/cli_pager.cpp:126:17:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        dup2(fd.read, STDIN_FILENO);
data/apitrace-9.0+repack/cli/cli_pager.cpp:144:18:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        close(fd.read);
data/apitrace-9.0+repack/cli/cli_repack.cpp:83:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    size_t read;
data/apitrace-9.0+repack/cli/cli_repack.cpp:85:28:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    while ((read = inFile->read(buf, size)) != 0) {
data/apitrace-9.0+repack/cli/cli_repack.cpp:86:29:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        outFile->write(buf, read);
data/apitrace-9.0+repack/cli/cli_repack.cpp:134:36:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
            available_in = inFile->read(input, kFileBufferSize);
data/apitrace-9.0+repack/cli/cli_repack.cpp:175:32:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        available_in = inFile->read(input, kFileBufferSize);
data/apitrace-9.0+repack/cli/pickle.hpp:209:24:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        writeString(s, strlen(s));
data/apitrace-9.0+repack/cli/pickle.hpp:241:25:  [1] (buffer) wcslen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        writeWString(s, wcslen(s));
data/apitrace-9.0+repack/gui/qubjson.cpp:200:18:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        Q_UNUSED(read);
data/apitrace-9.0+repack/gui/retracer.cpp:100:38:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        qint64 chunkSize = m_device->read(data + readSoFar, bytesToRead);
data/apitrace-9.0+repack/gui/retracer.cpp:490:43:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                    qint64 readBytes = io.read((char *) scanLine, rowBytes);
data/apitrace-9.0+repack/helpers/glsize.hpp:790:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
            GLsizei size = GLsizei(strlen(reinterpret_cast<const char*>(fontName))+1);
data/apitrace-9.0+repack/helpers/glsize.hpp:1241:16:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        return strlen(string[index]);
data/apitrace-9.0+repack/helpers/glsize.hpp:1260:21:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
            size += strlen(&string[size]) + 1;
data/apitrace-9.0+repack/inject/inject.h:245:30:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t szDllPathLength = strlen(szDllPath) + 1;
data/apitrace-9.0+repack/inject/injectee_iat.cpp:1146:13:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
            strncpy(szSharedMemCopy, pSharedMem->szDllName, _countof(szSharedMemCopy) - 1);
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:438:55:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
            if (strncmp(szFunctionName, "wglUseFont", strlen("wglUseFont")) == 0) {
data/apitrace-9.0+repack/inject/injectee_mhook.cpp:769:13:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
            strncpy(szSharedMemCopy, pSharedMem->szDllName, _countof(szSharedMemCopy) - 1);
data/apitrace-9.0+repack/inject/injector.cpp:230:5:  [1] (buffer) getchar:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    getchar();
data/apitrace-9.0+repack/inject/injector.cpp:587:9:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
        strncpy(pSharedMem->szDllName, szDll, _countof(pSharedMem->szDllName) - 1);
data/apitrace-9.0+repack/inject/injector.cpp:713:5:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
    strncat(szDllPath, szDllName, sizeof szDllPath - strlen(szDllPath) - 1);
data/apitrace-9.0+repack/inject/injector.cpp:713:54:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    strncat(szDllPath, szDllName, sizeof szDllPath - strlen(szDllPath) - 1);
data/apitrace-9.0+repack/inject/injector.cpp:740:13:  [1] (buffer) getchar:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
            getchar();
data/apitrace-9.0+repack/lib/image/image_png.cpp:188:9:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    os->read((char *)data, length);
data/apitrace-9.0+repack/lib/os/os_backtrace.cpp:98:37:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        return pset.find(pstring(s, strlen(s) + 1)) != pset.end();
data/apitrace-9.0+repack/lib/os/os_backtrace.cpp:112:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (tok[strlen(tok) - 1] == '*')
data/apitrace-9.0+repack/lib/os/os_backtrace.cpp:113:28:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
            addPrefix(tok, strlen(tok) - 1);
data/apitrace-9.0+repack/lib/os/os_backtrace.cpp:115:28:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
            addPrefix(tok, strlen(tok) + 1);
data/apitrace-9.0+repack/lib/os/os_backtrace.cpp:307:35:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
#define DUMP(string) dump(string, strlen(string))
data/apitrace-9.0+repack/lib/os/os_posix.cpp:94:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    len = strlen(buf);
data/apitrace-9.0+repack/lib/os/os_posix.cpp:113:19:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
            len = read(fd, buf, size);
data/apitrace-9.0+repack/lib/os/os_posix.cpp:116:23:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                len = strlen(buf);
data/apitrace-9.0+repack/lib/os/os_posix.cpp:124:15:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        len = strlen(program_invocation_name);
data/apitrace-9.0+repack/lib/os/os_posix.cpp:445:14:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    int sz = read(fd, statmBuff, 255);
data/apitrace-9.0+repack/lib/os/os_string.hpp:186:23:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        buffer(s, s + strlen(s) + 1)
data/apitrace-9.0+repack/lib/os/os_string.hpp:299:33:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        insert(position, s, s + strlen(s));
data/apitrace-9.0+repack/lib/os/os_string.hpp:355:16:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        assert(strlen(&buffer[0]) == length);
data/apitrace-9.0+repack/lib/os/os_string.hpp:363:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        truncate(strlen(&buffer[0]));
data/apitrace-9.0+repack/lib/os/os_time.hpp:99:9:  [1] (obsolete) usleep:
  This C routine is considered obsolete (as opposed to the shell command by
  the same name). The interaction of this function with SIGALRM and other
  timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is
  unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead.
        usleep(usecs);
data/apitrace-9.0+repack/lib/trace/trace_file.hpp:58:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    size_t read(void *buffer, size_t length);
data/apitrace-9.0+repack/lib/trace/trace_file.hpp:60:9:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    int getc(void);
data/apitrace-9.0+repack/lib/trace/trace_file.hpp:94:21:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
inline size_t File::read(void *buffer, size_t length)
data/apitrace-9.0+repack/lib/trace/trace_file.hpp:118:18:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
inline int File::getc(void)
data/apitrace-9.0+repack/lib/trace/trace_file_brotli.cpp:102:22:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
            m_stream.read((char *)input, kFileBufferSize);
data/apitrace-9.0+repack/lib/trace/trace_file_snappy.cpp:227:14:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    m_stream.read((char*)m_compressedCache, compressedLength);
data/apitrace-9.0+repack/lib/trace/trace_file_snappy.cpp:280:14:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    m_stream.read((char *)buf, sizeof buf);
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:804:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    file->read(&value, sizeof value);
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:816:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    file->read(&value, sizeof value);
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:898:15:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        file->read(blob->buf, size);
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:983:15:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        file->read(value, len);
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:1031:19:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        c = file->getc();
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:1048:19:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        c = file->getc();
data/apitrace-9.0+repack/lib/trace/trace_parser.cpp:1057:19:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    int c = file->getc();
data/apitrace-9.0+repack/lib/trace/trace_profiler.cpp:174:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    if (in[0] == '#' || strlen(in) < 4)
data/apitrace-9.0+repack/lib/trace/trace_writer.cpp:136:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t len = strlen(str);
data/apitrace-9.0+repack/lib/trace/trace_writer.cpp:197:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    assert(strlen(name));
data/apitrace-9.0+repack/lib/trace/trace_writer.cpp:334:18:  [1] (buffer) wcslen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t len = wcslen(str);
data/apitrace-9.0+repack/retrace/glretrace_main.cpp:788:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t messageLen = strlen(message);
data/apitrace-9.0+repack/retrace/glstate.cpp:595:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t messageLen = strlen(message);
data/apitrace-9.0+repack/retrace/glws_glx.cpp:430:9:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    if (read != draw)
data/apitrace-9.0+repack/retrace/glws_glx.cpp:431:53:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        return glXMakeContextCurrent(display, draw, read, ctx);
data/apitrace-9.0+repack/retrace/metric_helper.cpp:212:50:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    parseBackendBlock(pollingRule, metrics, std::strlen(metrics), backendsHash);
data/apitrace-9.0+repack/retrace/retrace_main.cpp:770:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t len = strlen(s2);
data/apitrace-9.0+repack/retrace/retrace_main.cpp:807:53:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        adjustedName.resize(adjustedName.length() - strlen(".exe"));
data/apitrace-9.0+repack/retrace/state_writer_ubjson.cpp:85:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        size_t len = strlen(name);
data/apitrace-9.0+repack/retrace/state_writer_ubjson.cpp:105:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        size_t len = strlen(s);
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:157:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
  size_t unbrotli_len = strlen(unbrotli);
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:187:28:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t arg_len = arg ? strlen(arg) : 0;
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:691:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
  arg_len = strlen(arg);
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:710:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t suffix_len = strlen(context->suffix);
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:713:23:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t name_len = strlen(name);
data/apitrace-9.0+repack/thirdparty/brotli/c/tools/brotli.c:1014:38:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
          context.longest_path_len + strlen(context.suffix) + 1;
data/apitrace-9.0+repack/thirdparty/khronos/EGL/egl.h:141:102:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
typedef EGLBoolean (EGLAPIENTRYP PFNEGLMAKECURRENTPROC) (EGLDisplay dpy, EGLSurface draw, EGLSurface read, EGLContext ctx);
data/apitrace-9.0+repack/thirdparty/khronos/EGL/egl.h:166:91:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
EGLAPI EGLBoolean EGLAPIENTRY eglMakeCurrent (EGLDisplay dpy, EGLSurface draw, EGLSurface read, EGLContext ctx);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glx.h:284:84:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
extern Bool glXMakeContextCurrent (Display *display, GLXDrawable draw, GLXDrawable read, GLXContext ctx);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h:122:92:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
typedef Bool ( *PFNGLXMAKECONTEXTCURRENTPROC) (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h:140:73:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
Bool glXMakeContextCurrent (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h:931:92:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
typedef Bool ( *PFNGLXMAKECURRENTREADSGIPROC) (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx);
data/apitrace-9.0+repack/thirdparty/khronos/GL/glxext.h:934:73:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
Bool glXMakeCurrentReadSGI (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx);
data/apitrace-9.0+repack/wrappers/config.cpp:116:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    if (strncmp(string, keyword, strlen(keyword)) == 0)
data/apitrace-9.0+repack/wrappers/dlltrace.hpp:59:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                strncpy(szSystemDir, pathOverride, MAX_PATH);
data/apitrace-9.0+repack/wrappers/glcaps.cpp:130:28:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    size_t extensionsLen = strlen(extensions);
data/apitrace-9.0+repack/wrappers/glcaps.cpp:135:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        size_t extraExtensionLen = strlen(extraExtension);
data/apitrace-9.0+repack/wrappers/glcaps.cpp:159:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        size_t extraExtensionLen = strlen(extraExtension);

ANALYSIS SUMMARY:

Hits = 461
Lines analyzed = 263552 in approximately 11.07 seconds (23814 lines/second)
Physical Source Lines of Code (SLOC) = 234093
Hits@level = [0] 145 [1]  89 [2] 250 [3]  41 [4]  72 [5]   9
Hits@level+ = [0+] 606 [1+] 461 [2+] 372 [3+] 122 [4+]  81 [5+]   9
Hits/KSLOC@level+ = [0+] 2.58871 [1+] 1.9693 [2+] 1.58911 [3+] 0.52116 [4+] 0.346016 [5+] 0.0384463
Dot directories skipped = 1 (--followdotdir overrides)
Minimum risk level = 1
Not every hit is necessarily a security vulnerability.
There may be other security vulnerabilities; review your code!
See 'Secure Programming HOWTO'
(https://dwheeler.com/secure-programs) for more information.