# initscripts-10.25-1.20240808102801165023.main.1.g67743ca1

## List of Findings

    Error: GCC_ANALYZER_WARNING (CWE-775): [#def1]
    initscripts-10.25-build/initscripts-10.25/src/genhostid.c: scope_hint: In function ‘main’
    initscripts-10.25-build/initscripts-10.25/src/genhostid.c:45:16: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/random", 0)’
    #   43|     int fd = open ("/dev/random", O_RDONLY);
    #   44|
    #   45|->   if (fd == -1 || read (fd, &n, sizeof (n)) != sizeof (n)) {
    #   46|       srand48 ((long int) time (NULL) ^ (long int) getpid ());
    #   47|       n = lrand48 ();

## Scan Properties

analyzer-version-clippy | 1.80.1
analyzer-version-cppcheck | 2.14.2
analyzer-version-gcc | 14.1.1
analyzer-version-gcc-analyzer | 14.1.1
analyzer-version-shellcheck | 0.10.0
analyzer-version-unicontrol | 0.0.2
enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol
exit-code | 0
host | ip-172-16-1-105.us-west-2.compute.internal
mock-config | fedora-rawhide-x86_64
project-name | initscripts-10.25-1.20240808102801165023.main.1.g67743ca1
store-results-to | /tmp/tmpuannrlo3/initscripts-10.25-1.20240808102801165023.main.1.g67743ca1.tar.xz
time-created | 2024-08-14 14:23:35
time-finished | 2024-08-14 14:24:56
tool | csmock
tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'clippy,gcc,cppcheck,shellcheck,unicontrol' '-o' '/tmp/tmpuannrlo3/initscripts-10.25-1.20240808102801165023.main.1.g67743ca1.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '/tmp/tmpuannrlo3/initscripts-10.25-1.20240808102801165023.main.1.g67743ca1.src.rpm'
tool-version | csmock-3.6.1-1.el9