Sunday, October 11, 2026
HomeiOS DevelopmentC++ Obtain rename and save file with RemoteZip (python)

C++ Obtain rename and save file with RemoteZip (python)

[ad_1]

it is the primary publish I publish. I’ve a bit of code in c ++ that I want to switch to make it work on M1. The aim of this code is to take the trail of the file to be downloaded from the .plist file, and thru remotezip (python) obtain it, take away the trail and reserve it within the vacation spot folder. nevertheless, in relation to recalling the file from the server, I obtain segmentation faults. I’ve no approach to debug the code. Thanks upfront for who will assist me.

//this line permits me to accurately obtain the Manifest.plist is on the Root of the zip and i haven’t got any downside.

system((std::string("remotezip ") + zip.hyperlink + " " + "Manifest.plist ").c_str());

Inside M.plist we search for the proper path of bss, there are a number of bss file in numerous folders, however differ by board within the title.

std::string BSS(std::string board){

//Working Path for Obtain 
chdir((std::string("WorkD_") + identifier + "_" + model).c_str());

std::ifstream Manifest("Manifest.plist");
 whereas(getline(Manifest, bss.path)) {

//Choose the one matching with Board enter.

  if(bss.path.discover(board) != std::string::npos) {
   for(int i = 0; i < 4000 && getline(Manifest, bss.path); i++) {
    if(bss.path.discover("BSS.")!= std::string::npos) {
     Manifest.shut();
      bss.path.erase(0, 14);
       for(int y = 0; y < bss.path.dimension(); y++) {
        if(bss.path[y] == '<') {
         bss.path.erase(y);

//Distant zip work provided that the trail is full like remotezip google.com /information/random/bss and it'll additionally mkdir information and random..I imagine that is the issue.
         
          system((std::string("remotezip") + zip.hyperlink + " " + bss.path).c_str());
           bss.path.erase(0, 13);
            bss.title = bss.path;
        }
       }
      }
     }
    }
   }
  return bss.title;
  }

[ad_2]

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments