Project

General

Profile

Actions

Bug #2657

closed

ArrayIndexOutOfBoundsException thrown during creating exception message

Added by Harezlak Daniel over 12 years ago. Updated over 12 years ago.

Status:
Resolved
Priority:
Low
Assigned To:
Category:
gLite adaptors
Target version:
-
Start date:
04/04/2012
Due date:
% Done:

0%

Estimated time:

Description

The stacktrace is the following:

java.lang.ArrayIndexOutOfBoundsException: 7
        at fr.in2p3.jsaga.adaptor.wms.job.WMSJobControlAdaptor.createExceptionMessage(WMSJobControlAdaptor.java:428)
        at fr.in2p3.jsaga.adaptor.wms.job.WMSJobControlAdaptor.rethrow(WMSJobControlAdaptor.java:390)
        at fr.in2p3.jsaga.adaptor.wms.job.WMSJobControlAdaptor.submit(WMSJobControlAdaptor.java:253)
        at fr.in2p3.jsaga.impl.job.instance.AbstractSyncJobImpl.doSubmit(AbstractSyncJobImpl.java:228)
        at fr.in2p3.jsaga.impl.task.AbstractTaskImpl.run(AbstractTaskImpl.java:102)
        at fr.in2p3.jsaga.impl.job.instance.JobImpl.run(JobImpl.java:47)

After looking at the code of WMSJobControlAdaptor.java the fault lies in the date = dayStr[calendar.get(Calendar.DAY_OF_WEEK)] + " " line. The values of the calendar.get(Calendar.DAY_OF_WEEK) expression vary from 1 to 7 while the indexes of the dayStr array take values from 0 to 6.

Actions

Also available in: Atom PDF