eventattacher: fix out of bounds string access
Change-Id: Ic1f7ac2b6c3f5a865b316a83d92a0f2ff7616f5c
This commit is contained in:
parent
44c90b3d75
commit
9fd15d9e37
@ -624,7 +624,7 @@ Reference<XEventListener> EventAttacherImpl::attachListenerForTarget(
|
|||||||
else
|
else
|
||||||
nIndex++;
|
nIndex++;
|
||||||
|
|
||||||
OUString aListenerName = (aListenerType[nIndex] == 'X') ? aListenerType.copy(nIndex+1) : aListenerType;
|
OUString aListenerName = (!aListenerType.isEmpty() && aListenerType[nIndex] == 'X') ? aListenerType.copy(nIndex+1) : aListenerType;
|
||||||
OUString aAddListenerName = "add" + aListenerName;
|
OUString aAddListenerName = "add" + aListenerName;
|
||||||
|
|
||||||
// Send Methods to the correct addListener-Method
|
// Send Methods to the correct addListener-Method
|
||||||
|
Loading…
x
Reference in New Issue
Block a user