Bug #4114
MESSAGE throws ArrayIndexOutOfBoundsException with long output
Status:
New
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
06/12/2019
Due date:
% Done:
0%
billable:
No
vendor_id:
GCD
case_num:
version_reported:
version_resolved:
reviewer:
production:
No
env_name:
topics:
History
#1 Updated by Igor Skornyakov about 7 years ago
The converted code
PROCEDURE dump:
DEF INPUT PARAM step AS CHAR.
DEF VAR token AS raw NO-UNDO.
DEF VAR hex AS CHAR NO-UNDO.
token = hcp:EXPORT-PRINCIPAL().
hex = HEX-ENCODE(token).
MESSAGE step hex.
END.
throws ArrayIndexOutOfBoundsException in MESSAGE if hex is longer than 512 chars.
aused by: java.lang.ArrayIndexOutOfBoundsException: 512
at com.goldencode.p2j.ui.chui.RedirectedTerminal.addChar(RedirectedTerminal.java:1137)
at com.goldencode.p2j.ui.chui.RedirectedTerminal.append(RedirectedTerminal.java:366)
at com.goldencode.p2j.ui.client.chui.driver.ChuiOutputManager.append(ChuiOutputManager.java:360)
at com.goldencode.p2j.ui.client.chui.driver.ChuiOutputManager.append(ChuiOutputManager.java:96)
at com.goldencode.p2j.ui.chui.ThinClient.sendToStream(ThinClient.java:3750)
at com.goldencode.p2j.ui.client.gui.WindowGuiImpl.message(WindowGuiImpl.java:1261)
at com.goldencode.p2j.ui.client.Window.message(Window.java:2027)
at com.goldencode.p2j.ui.chui.ThinClient.message(ThinClient.java:8308)
at com.goldencode.p2j.ui.ClientExportsMethodAccess.invoke(Unknown Source)
at com.goldencode.p2j.util.MethodInvoker.invoke(MethodInvoker.java:156)
at com.goldencode.p2j.net.Dispatcher.processInbound(Dispatcher.java:757)
at com.goldencode.p2j.net.Conversation.block(Conversation.java:412)
at com.goldencode.p2j.net.Conversation.waitMessage(Conversation.java:348)
at com.goldencode.p2j.net.Queue.transactImpl(Queue.java:1201)
at com.goldencode.p2j.net.Queue.transact(Queue.java:672)
at com.goldencode.p2j.net.BaseSession.transact(BaseSession.java:271)
at com.goldencode.p2j.net.HighLevelObject.transact(HighLevelObject.java:211)
at com.goldencode.p2j.net.RemoteObject$RemoteAccess.invokeCore(RemoteObject.java:1473)
at com.goldencode.p2j.net.InvocationStub.invoke(InvocationStub.java:145)
The output was redirected to a file.