-->\r
<manifest package="eu.alefzero.owncloud"\r
android:versionCode="1"\r
- android:versionName="0.1.146B" xmlns:android="http://schemas.android.com/apk/res/android">\r
+ android:versionName="0.1.147B" xmlns:android="http://schemas.android.com/apk/res/android">\r
\r
<uses-permission android:name="android.permission.GET_ACCOUNTS" />\r
<uses-permission android:name="android.permission.USE_CREDENTIALS" />\r
}\r
\r
public boolean downloadFile(String remoteFilepath, File targetPath) {\r
- // HttpGet get = new HttpGet(mUri.toString() + filepath.replace(" ",\r
- // "%20"));\r
- /* dvelasco - this is not necessary anymore; OCFile.mRemotePath (the origin of remoteFielPath) keeps valid URL strings\r
- String[] splitted_filepath = remoteFilepath.split("/");\r
- remoteFilepath = "";\r
- for (String s : splitted_filepath) {\r
- if (s.equals("")) continue;\r
- remoteFilepath += "/" + URLEncoder.encode(s);\r
- }\r
-\r
- Log.e("ASD", mUri.toString() + remoteFilepath.replace(" ", "%20") + "");\r
- GetMethod get = new GetMethod(mUri.toString()\r
- + remoteFilepath.replace(" ", "%20"));\r
- */\r
GetMethod get = new GetMethod(mUri.toString() + remoteFilepath);\r
+ HttpMethodParams params = get.getParams();\r
+ params.setSoTimeout(0); // that means "infinite timeout"; it's the default value, but let's make it explicit\r
+ get.setParams(params);\r
\r
// get.setHeader("Host", mUri.getHost());\r
// get.setHeader("User-Agent", "Android-ownCloud");\r
entity.setOnDatatransferProgressListener(mDataTransferListener);\r
Log.e("ASD", f.exists() + " " + entity.getContentLength());\r
PutMethod put = new PutMethod(mUri.toString() + remoteTarget);\r
+ HttpMethodParams params = put.getParams();\r
+ params.setSoTimeout(0); // that means "infinite timeout"; it's the default value, but let's make it explicit\r
+ put.setParams(params);\r
put.setRequestEntity(entity);\r
Log.d(TAG, "" + put.getURI().toString());\r
int status = executeMethod(put);\r