Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 20 Aug 2015 06:31:33 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 202507] usr/src/tests/sys/aio/lio_kqueue_test.c:82: buffer too small ?
Message-ID:  <bug-202507-8@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=202507

            Bug ID: 202507
           Summary: usr/src/tests/sys/aio/lio_kqueue_test.c:82: buffer too
                    small ?
           Product: Base System
           Version: 11.0-CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: misc
          Assignee: freebsd-bugs@FreeBSD.org
          Reporter: dcb314@hotmail.com

[usr/src/tests/sys/aio/lio_kqueue_test.c:82]: (error) Buffer is accessed out of
bounds: pathname

Source code is

        strcpy(pathname, PATH_TEMPLATE);

but

    char *file, pathname[sizeof(PATH_TEMPLATE)-1];

Maybe better code

    char *file, pathname[sizeof(PATH_TEMPLATE) + 1];

-- 
You are receiving this mail because:
You are the assignee for the bug.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-202507-8>