title: How to use cp (Copy) command in system function in native C code on Android
body: <p>I want to copy file from on directory to another in my native C program.
  I tried using <code>system</code> function but it's not working.</p>
  
  <p>I tried this code in native code of Android</p>
  
  <pre><code>int result = system("cp /mnt/test /Download/"); // It's not working
  </code></pre>
  
  <p>This system function returns <code>256</code> (error code) integer value. So we can say system function is working in Android.  I also installed BusyBox so I can use the <code>cp</code> command also.</p>
  
  <p>If I execute directly <code>cp /mnt/test /Download/</code> command then it's working fine.</p>
  
  <p>So what is problem here in <code>system</code> function.   Have I missed something?</p>