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/kwindowsystem-5.74.0/autotests/compositingenabled_test.cpp
Examining data/kwindowsystem-5.74.0/autotests/netwininfotestclient.cpp
Examining data/kwindowsystem-5.74.0/autotests/kmanagerselectiontest.cpp
Examining data/kwindowsystem-5.74.0/autotests/helper/wayland_platform.cpp
Examining data/kwindowsystem-5.74.0/autotests/kwindoweffectstest.cpp
Examining data/kwindowsystem-5.74.0/autotests/fixx11h_test2.cpp
Examining data/kwindowsystem-5.74.0/autotests/kwindowsystemx11test.cpp
Examining data/kwindowsystem-5.74.0/autotests/dontcrashmapviewport.cpp
Examining data/kwindowsystem-5.74.0/autotests/fixx11h_test.cpp
Examining data/kwindowsystem-5.74.0/autotests/netrootinfotestwm.cpp
Examining data/kwindowsystem-5.74.0/autotests/nettesthelper.h
Examining data/kwindowsystem-5.74.0/autotests/kwindowsystem_threadtest.cpp
Examining data/kwindowsystem-5.74.0/autotests/kwindowsystem_platform_wayland_test.cpp
Examining data/kwindowsystem-5.74.0/autotests/kmanagerselectiontest.h
Examining data/kwindowsystem-5.74.0/autotests/kxmessages_unittest.cpp
Examining data/kwindowsystem-5.74.0/autotests/kstartupinfo_unittest.cpp
Examining data/kwindowsystem-5.74.0/autotests/kkeyserver_x11_unittest.cpp
Examining data/kwindowsystem-5.74.0/autotests/kwindowinfox11test.cpp
Examining data/kwindowsystem-5.74.0/autotests/netwininfotestwm.cpp
Examining data/kwindowsystem-5.74.0/tests/setmainwindowtest.cpp
Examining data/kwindowsystem-5.74.0/tests/icontest.cpp
Examining data/kwindowsystem-5.74.0/tests/createpixmapfromhandletest.cpp
Examining data/kwindowsystem-5.74.0/tests/backgroundcontrasttest.cpp
Examining data/kwindowsystem-5.74.0/tests/blurbehindtest.cpp
Examining data/kwindowsystem-5.74.0/src/kwindowinfo.cpp
Examining data/kwindowsystem-5.74.0/src/kkeyserver.cpp
Examining data/kwindowsystem-5.74.0/src/kwindoweffects_p.h
Examining data/kwindowsystem-5.74.0/src/kwindowsystemplugininterface_p.h
Examining data/kwindowsystem-5.74.0/src/kwindoweffects.h
Examining data/kwindowsystem-5.74.0/src/kwindowsystem.h
Examining data/kwindowsystem-5.74.0/src/kwindowsystem.cpp
Examining data/kwindowsystem-5.74.0/src/kwindowinfo_p.h
Examining data/kwindowsystem-5.74.0/src/kstartupinfo.cpp
Examining data/kwindowsystem-5.74.0/src/kwindoweffects_dummy_p.h
Examining data/kwindowsystem-5.74.0/src/kwindowshadow.cpp
Examining data/kwindowsystem-5.74.0/src/kusertimestamp.h
Examining data/kwindowsystem-5.74.0/src/kwindowsystem_p.h
Examining data/kwindowsystem-5.74.0/src/kwindowsystemplugininterface.cpp
Examining data/kwindowsystem-5.74.0/src/kwindowshadow.h
Examining data/kwindowsystem-5.74.0/src/platforms/osx/kkeyserver_mac.h
Examining data/kwindowsystem-5.74.0/src/platforms/osx/kwindowinfo.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/osx/kkeyserver.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/osx/kwindowsystem.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/osx/kwindowinfo_mac_p.h
Examining data/kwindowsystem-5.74.0/src/platforms/windows/kwindowinfo.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/windows/kkeyserver.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/windows/kkeyserver_win.h
Examining data/kwindowsystem-5.74.0/src/platforms/windows/kwindowsystem.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/wayland/kwindowsystem.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/wayland/plugin.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/wayland/kwindowsystem_p_wayland.h
Examining data/kwindowsystem-5.74.0/src/platforms/wayland/plugin.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/netwm_p.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kwindoweffects_x11.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowinfo.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kkeyserver.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kselectionowner.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/atoms_p.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowsystem.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kkeyserver_x11.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowsystem_p_x11.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/plugin.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowshadow.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kxerrorhandler_p.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowshadow_p_x11.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kselectionowner.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kxmessages.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kselectionwatcher.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kwindoweffects.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kxutils_p.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kxerrorhandler.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowinfo_p_x11.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kselectionwatcher.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kxutils.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/fixx11h.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kmanagerselection.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/kxmessages.h
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp
Examining data/kwindowsystem-5.74.0/src/platforms/xcb/plugin.h
Examining data/kwindowsystem-5.74.0/src/kwindowshadow_dummy_p.h
Examining data/kwindowsystem-5.74.0/src/kusertimestamp.cpp
Examining data/kwindowsystem-5.74.0/src/pluginwrapper_p.h
Examining data/kwindowsystem-5.74.0/src/kwindowinfo.h
Examining data/kwindowsystem-5.74.0/src/kwindoweffects.cpp
Examining data/kwindowsystem-5.74.0/src/kkeyserver.h
Examining data/kwindowsystem-5.74.0/src/netwm_def.h
Examining data/kwindowsystem-5.74.0/src/kwindoweffects_dummy.cpp
Examining data/kwindowsystem-5.74.0/src/kwindowshadow_p.h
Examining data/kwindowsystem-5.74.0/src/kwindowsystem_dummy_p.h
Examining data/kwindowsystem-5.74.0/src/pluginwrapper.cpp
Examining data/kwindowsystem-5.74.0/src/kstartupinfo.h
Examining data/kwindowsystem-5.74.0/src/kwindowinfo_dummy_p.h

FINAL RESULTS:

data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:726:13:  [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(propp, p->desktop_names[i]);
data/kwindowsystem-5.74.0/src/platforms/windows/kwindowinfo.cpp:279:23:  [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.
    resourcenamevar = getenv("RESOURCE_NAME");
data/kwindowsystem-5.74.0/autotests/netrootinfotestwm.cpp:94: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).
    QVERIFY(readPipe.open(pipeFds[0], QIODevice::ReadOnly, QFileDevice::AutoCloseHandle));
data/kwindowsystem-5.74.0/autotests/netwininfotestclient.cpp:135: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).
    QVERIFY(readPipe.open(pipeFds[0], QIODevice::ReadOnly, QFileDevice::AutoCloseHandle));
data/kwindowsystem-5.74.0/autotests/netwininfotestwm.cpp:118: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).
    QVERIFY(readPipe.open(pipeFds[0], QIODevice::ReadOnly, QFileDevice::AutoCloseHandle));
data/kwindowsystem-5.74.0/src/kstartupinfo.cpp:1083: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 hostname[ 256 ];
data/kwindowsystem-5.74.0/src/kstartupinfo.cpp:1484: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 tmp[ 256 ];
data/kwindowsystem-5.74.0/src/platforms/osx/kwindowinfo.cpp:46: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 processName[512];
data/kwindowsystem-5.74.0/src/platforms/windows/kwindowinfo.cpp:297:5:  [2] (buffer) TCHAR:
  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.
    TCHAR name[max];
data/kwindowsystem-5.74.0/src/platforms/windows/kwindowsystem.cpp:99: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(bits.data() + y * bpl, im.scanLine(y), bpl);
data/kwindowsystem-5.74.0/src/platforms/xcb/kkeyserver.cpp:900: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[16];
data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowsystem.cpp:404:15:  [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 *names[max];
data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowsystem.cpp:417: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 net_wm_cm_name[ 100 ];
data/kwindowsystem-5.74.0/src/platforms/xcb/kwindowsystem.cpp:418:9:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        sprintf(net_wm_cm_name, "_NET_WM_CM_S%d", QX11Info::appScreen());
data/kwindowsystem-5.74.0/src/platforms/xcb/kxerrorhandler.cpp:126: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 tmp[ 256 ];
data/kwindowsystem-5.74.0/src/platforms/xcb/kxerrorhandler.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 num[ 256 ];
data/kwindowsystem-5.74.0/src/platforms/xcb/kxerrorhandler.cpp:195:17:  [2] (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). Risk is low because the source is a constant string.
                strcpy(tmp, "<unknown>");
data/kwindowsystem-5.74.0/src/platforms/xcb/kxerrorhandler.cpp:202:76:  [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.
            ret = QByteArray("error: ") + (const char *)tmp + '[' + (const char *)extensions[ index ]
data/kwindowsystem-5.74.0/src/platforms/xcb/kxerrorhandler.cpp:214:85:  [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.
                ret += QByteArray(", request: ") + (const char *)tmp + '[' + (const char *)extensions[ i ] + '+'
data/kwindowsystem-5.74.0/src/platforms/xcb/kxmessages.cpp:139: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 buf[ 21 ]; // can't be longer
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:210: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((void *)&vector.first(), (void *)data, reply->value_len * sizeof(T));
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:349: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((void *)icons[i].data, (const void *)&data[j], size);
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:2764: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(d, icon.data, sz * sizeof(uint32_t));
data/kwindowsystem-5.74.0/src/platforms/xcb/kselectionowner.cpp:36:89:  [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).
    xcb_intern_atom_reply_t *reply = xcb_intern_atom_reply(c, xcb_intern_atom(c, false, strlen(name), name), nullptr);
data/kwindowsystem-5.74.0/src/platforms/xcb/kselectionowner.cpp:575:48:  [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).
        cookies[i] = xcb_intern_atom(c, false, strlen(atoms[i].name), atoms[i].name);
data/kwindowsystem-5.74.0/src/platforms/xcb/kselectionwatcher.cpp:34:89:  [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).
    xcb_intern_atom_reply_t *reply = xcb_intern_atom_reply(c, xcb_intern_atom(c, false, strlen(name), name), nullptr);
data/kwindowsystem-5.74.0/src/platforms/xcb/kselectionwatcher.cpp:155:74:  [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).
        xcb_intern_atom_cookie_t atom_cookie = xcb_intern_atom(c, false, strlen("MANAGER"), "MANAGER");
data/kwindowsystem-5.74.0/src/platforms/xcb/kxmessages.cpp:156: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(buf) < 20) { // last message fragment
data/kwindowsystem-5.74.0/src/platforms/xcb/kxmessages.cpp:291: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).
    unsigned int len = strlen(msg.constData());
data/kwindowsystem-5.74.0/src/platforms/xcb/kxmessages.cpp:318: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).
    const size_t len = strlen(msg.constData());
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:80: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).
    int l = strlen(s1) + 1;
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:82:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(s2, s1, l);
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:93:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(s2, s1, l);
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:290:59:  [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).
        cookies[i] = xcb_intern_atom(m_connection, false, strlen(KwsAtomStrings[i]), KwsAtomStrings[i]);
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:719: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).
        proplen += (p->desktop_names[i] != nullptr ? strlen(p->desktop_names[i]) + 1 : 1);
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:727: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).
            propp += strlen(p->desktop_names[i]) + 1;
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:1156:73:  [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).
                        p->atom(_NET_WM_NAME), p->atom(UTF8_STRING), 8, strlen(p->name),
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:3265: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).
                            p->atom(UTF8_STRING), 8, strlen(p->name), (const void *) p->name);
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:3282: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).
                            p->atom(UTF8_STRING), 8, strlen(p->visible_name),
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:3300: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).
                            p->atom(UTF8_STRING), 8, strlen(p->icon_name),
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:3318: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).
                            p->atom(UTF8_STRING), 8, strlen(p->visible_icon_name),
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:3396: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).
                        p->atom(UTF8_STRING), 8, strlen(p->startup_id),
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:3543:45:  [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).
                        XCB_ATOM_STRING, 8, strlen(p->appmenu_object_path),
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:3557:45:  [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).
                        XCB_ATOM_STRING, 8, strlen(p->appmenu_service_name),
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:4928:45:  [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).
                        XCB_ATOM_STRING, 8, strlen(p->activities), p->activities);
data/kwindowsystem-5.74.0/src/platforms/xcb/netwm.cpp:5005: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).
                        p->atom(UTF8_STRING), 8, strlen(p->desktop_file),

ANALYSIS SUMMARY:

Hits = 46
Lines analyzed = 30258 in approximately 1.02 seconds (29683 lines/second)
Physical Source Lines of Code (SLOC) = 20694
Hits@level = [0]  82 [1]  23 [2]  21 [3]   1 [4]   1 [5]   0
Hits@level+ = [0+] 128 [1+]  46 [2+]  23 [3+]   2 [4+]   1 [5+]   0
Hits/KSLOC@level+ = [0+] 6.18537 [1+] 2.22287 [2+] 1.11143 [3+] 0.0966464 [4+] 0.0483232 [5+]   0
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.