android - Interrupted AsyncTask -


i have asynctask make call webservice using defaulthttpclient().

if execution stops reason (i.e. when i'm debugging , press "terminate"), next call result in "refused connection" or timeout.

code called function within of doinbackground() :

    string response = null;      httpclient httpclient = new defaulthttpclient();     httppost httppost = new httppost(url);      soapenvelope env = new soapenvelope();     env.setservicenamespace(namespace);     env.setmethodname(methodname);     env.setparams(params);      stringentity se = new stringentity(env.serialize(), http.utf_8);     se.setcontenttype("text/xml");     httppost.setentity(se);      httpresponse httpresponse = httpclient.execute(httppost);     httpentity resentity = httpresponse.getentity(); 

it stuck on

    httpresponse httpresponse = httpclient.execute(httppost); 

restarting app doesn't work.

if restart device works again.

why behave this?


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -