title: java.lang.System.arraycopy (Native Method) freezes CPU cores
body: <p>We have a web app build with JSF1.2, Richfaces 3.3.2SR1 in a CentOS 5.5 with kernel java: 1.6.020, and java 1.6.20 running a tomcat 6.0.20.</p>
  
  <p>Days ago, java just starts to freeze, using a entire core of CPU, forcing us to do a ugly <code>kill -9</code> in the java process.</p>
  
  <p>I got the following exception.</p>
  
  <pre><code>Feb 1, 2012 5:04:19 PM com.sun.faces.lifecycle.LifecycleImpl phase
  WARNING: phase(RESTORE_VIEW 1,com.sun.faces.context.FacesContextImpl@fea29c) threw exception: java.lang.ArrayIndexOutOfBoundsException null
  java.lang.System.arraycopy(Native Method)
  org.ajax4jsf.request.MultipartRequest.fillBuffer(MultipartRequest.java:396)
  org.ajax4jsf.request.MultipartRequest.initialize(MultipartRequest.java:600)
  org.ajax4jsf.request.MultipartRequest.parseRequest(MultipartRequest.java:616)
  org.richfaces.component.FileUploadPhaselistener.beforePhase(FileUploadPhaselistener.java:63)
  com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:215)
  com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:113)
  javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
  org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
  org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:178)
  org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290)
  org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:367)
  org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:515)
  ......
  </code></pre>
  
  <p>I think that the fileupload are generating this exception some way, but, I dont know how to solve...</p>
  
  <p>I do a lot of research, and the only <a href="https://issues.jboss.org/browse/RF-7927?page=com.atlassian.jira.plugin.system.issuetabpanels%3aall-tabpanel#issue-tabshttps://issues.jboss.org/browse/RF-7927?page=com.atlassian.jira.plugin.system.issuetabpanels%3aall-tabpanel#issue-tabs" rel="nofollow">link I found is this</a>, and it isnt useful at all. </p>
  
  <p>Someone else ever seen this before? I just dont know what to do, and I dont want to update all the things in a production server...</p>
  
  <p>Does anyone have a solution? Is there a java bug or something?</p>
  
  <p>Thanks in advance :)</p>