Closed Bug 933597 Opened 11 years ago Closed 11 years ago

widget/cocoa/TextInputHandler.mm:3842:5 [-Warray-bounds] array index 1 is past the end of the array (which contains 1 element)

Categories

(Core :: Widget: Cocoa, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 925031

People

(Reporter: cpeterson, Unassigned)

References

(Blocks 1 open bug)

Details

When compiling a 32-bit debug build for OS X, I saw the following warning:

widget/cocoa/TextInputHandler.mm:3842:5 [-Warray-bounds] array index 1 is past the end of the array (which contains 1 element)

from the following code:

    InterfaceTypeList supportedServices;
    supportedServices[0] = kTextServiceDocumentInterfaceType;
    supportedServices[1] = kUnicodeDocumentInterfaceType;
    ::NewTSMDocument(2, supportedServices, &mPluginTSMDoc, 0);

because InterfaceTypeList is typedef'd as:

    typedef OSType InterfaceTypeList[1];

in http://webnnel.googlecode.com/svn/trunk/lib/Carbon.framework/Versions/A/Frameworks/HIToolbox.framework/Versions/A/Headers/TextServices.h
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → DUPLICATE
Marking this as security sensitive -- hopefully only temporarily.
Group: core-security
The bug of which this is a dup is no longer security-sensitive.
Group: core-security
You need to log in before you can comment on or make changes to this bug.