I use NanoHTTPD as web server in my Android App, it's OK when I lanuch session.parseBody() for the first time.
But it cause null error when I lanuch the session.parseBody() function for the second time,why?
Is there some bugs in the function session.parseBody()?
@Override
public Response serve(IHTTPSession session) {
Method method = session.getMethod();
if (Method.POST.equals(method)) {
Map<String, String> files = new HashMap<String, String>();
session.parseBody(files); //It's OK
String zipValue1=session.getParms().get("ActionZIPMultiple");
Utility.LogError("KK1: "+zipValue1);
session.parseBody(files); //It will cause error!
String zipValue2=session.getParms().get("ActionZIPMultiple");
Utility.LogError("KK2: "+zipValue2);
}
}