فهرست منبع

further findbugs/pmd fixes for new feature (sd card)

AndyScherzinger 8 سال پیش
والد
کامیت
aa3d3c262c

+ 1 - 19
src/com/owncloud/android/datamodel/FileDataStorageManager.java

@@ -724,23 +724,6 @@ public class FileDataStorageManager {
                 Log_OC.e(TAG, e.getMessage(), e);
                 throw e;
             }
-        } catch (IOException ex) {
-            ret = false;
-        } finally {
-            if (in != null) {
-                try {
-                    in.close();
-                } catch (IOException e) {
-                    Log_OC.d(TAG, e.getMessage(), e);
-                }
-            }
-            if (out != null) {
-                try {
-                    out.close();
-                } catch (IOException e) {
-                    Log_OC.d(TAG, e.getMessage(), e);
-                }
-            }
         }
 
         ArrayList<ContentProviderOperation> operations = new ArrayList<>(cursor.getCount());
@@ -748,8 +731,7 @@ public class FileDataStorageManager {
             do {
                 ContentValues cv = new ContentValues();
                 long fileId = cursor.getLong(cursor.getColumnIndex(ProviderTableMeta._ID));
-                String oldFileStoragePath =
-                        cursor.getString(cursor.getColumnIndex(ProviderTableMeta.FILE_STORAGE_PATH));
+                String oldFileStoragePath = cursor.getString(cursor.getColumnIndex(ProviderTableMeta.FILE_STORAGE_PATH));
 
                 if (oldFileStoragePath.startsWith(srcPath)) {
 

+ 1 - 1
src/com/owncloud/android/datastorage/providers/AbstractCommandLineStoragePoint.java

@@ -46,7 +46,7 @@ abstract class AbstractCommandLineStoragePoint extends AbstractStoragePointProvi
             return false;
         }
         return process != null && process.exitValue() == COMMAND_LINE_OK_RETURN_VALUE;
-    }#
+    }
 
     String getCommandLineResult() {
         StringBuilder s = new StringBuilder();