title: File not found in /data/user/0/[package name]/files directory but is found in /data/data/[package name]/files directory
body: <p>I am downloading a zip file from a server to my internal storage. It is saved to the <code>/data/data/[package name]/files</code> directory and I can view it with the device file explorer in Android Studio. But when I try to access it to unzip it, I get the following error:</p>
  
  <pre><code>java.io.FileNotFoundException: thezip.zip: open failed: ENOENT (No such file or directory)
  </code></pre>
  
  <p>When I call:</p>
  
  <pre><code>context.getFileDir();
  </code></pre>
  
  <p>it gives me the following directory:</p>
  
  <pre><code>/data/user/0/[package name]/files
  </code></pre>
  
  <p>Which is a symbolic link to the </p>
  
  <pre><code>/data/data/[package name]/files directory
  </code></pre>
  
  <p>So I should have access to the zip file, shouldn't I?</p>
  
  <p>What am I missing here? I want to be able to have any user that uses the app to have access to the files in the zip folder. Help!</p>
  
  <p><strong>EDIT</strong>: here is the code:</p>
  
  <pre><code>class DownloadFileAsync extends AsyncTask&lt;String, String, String&gt; {
      private Context context;
      private String fileName;
  
      public DownloadFileAsync(Context context, String fileName){
          this.context = context;
          this.fileName = fileName;
      }
  
      @Override
      protected void onPreExecute() {
          super.onPreExecute();
  
      }
  
      @Override
      protected String doInBackground(String... aurl) {
          downloadZipFile(aurl[0]);
          try {
              unzipFolder(fileName);
          } catch (IOException e) {
              e.printStackTrace();
          }
          return null;
  
      }
      protected void onProgressUpdate(String... progress) {
          Log.d("ANDRO_ASYNC",progress[0]);
  
      }
  
      @Override
      protected void onPostExecute(String unused) {
  
      }
  
      private void downloadZipFile(String link){
          int count;
  
          try {
  
              URL url = new URL(link);
              URLConnection connection = url.openConnection();
              connection.connect();
  
              int lenghtOfFile = connection.getContentLength();
              Log.d("ANDRO_ASYNC", "Lenght of file: " + lenghtOfFile);
  
             // File file = new File(context.getFilesDir(), fileName);
              File file = new File(context.getFilesDir(), fileName);
              Log.d("zzzz", file.toString());
              InputStream input = new BufferedInputStream(url.openStream());
              FileOutputStream output = new FileOutputStream(file);
  
              byte data[] = new byte[1024];
  
              long total = 0;
  
              while ((count = input.read(data)) != -1) {
                  total += count;
                  publishProgress(""+(int)((total*100)/lenghtOfFile));
                  output.write(data, 0, count);
              }
  
              output.flush();
              output.close();
              input.close();
          } catch (Exception e) {}
      }
  
      private void unzipFolder(String zippedFile) throws IOException {
              //Log.d("zzzz", context.getFilesDir().toString());
  
          byte[] buffer = new byte[1024];
          ZipInputStream zipInputStream = new ZipInputStream(new FileInputStream(zippedFile));
          ZipEntry zipEntry = zipInputStream.getNextEntry();
          while (zipEntry != null){
              String aFile = zipEntry.getName();
              File newFile = new File(context.getFilesDir(), aFile);
  //            File newFile = new File(context.getFilesDir(), aFile);
              FileOutputStream fileOutputStream = new FileOutputStream(newFile);
              int len;
              while ((len = zipInputStream.read(buffer)) &gt; 0){
                  fileOutputStream.write(buffer, 0, len);
              }
              fileOutputStream.close();
              zipEntry = zipInputStream.getNextEntry();
          }
  
          zipInputStream.closeEntry();
          zipInputStream.close();
  
      }
  }
  </code></pre>