主题: 为什么4.1.4的版本,为什么在XP系统下使用正常,而到2003下则报错。
作者: youlingken, 发布日期: 2012-12-24 17:01:55, 浏览数: 2812
操作系统: windows server 2003

浏览器版本: IE8

KindEditor版本: 4.1.4

BUG再现步骤:
1.当项目部署到4.1.4上面的时候,上传图片、上传文件报错。

2.错误如下:

org.apache.jasper.JasperException: An exception occurred processing JSP page /kindeditor/jsp/upload_json.jsp at line 81

78: //Struts2 璇锋眰 鍖呰杩囨护鍣�
79: MultiPartRequestWrapper wrapper = (MultiPartRequestWrapper) request; 
80: //鑾峰緱涓婁紶鐨勬枃浠跺悕 
81: String fileName = wrapper.getFileNames("imgFile")[0];//imgFile,imgFile,imgFile 
82: //鑾峰緱鏂囦欢杩囨护鍣�
83: File file = wrapper.getFiles("imgFile")[0]; 
84:   


Stacktrace:
	org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:521)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:430)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
	org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:88)
	org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176)
	org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145)
	org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92)
	org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:390)
	org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
	org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)


root cause

java.lang.NullPointerException
	org.apache.jsp.kindeditor.jsp.upload_005fjson_jsp._jspService(upload_005fjson_jsp.java:149)
	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:388)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
	org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:88)
	org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176)
	org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145)
	org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92)
	org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:390)
	org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
	org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter


期望结果: 上传正常。

但是,同样的程序,在XP下面则正常显示。项目是Java的项目。谢谢。



发表新帖 发表回复