Skip to content
Snippets Groups Projects
Commit 2d5d898d authored by Israel Barreto Sant'Anna's avatar Israel Barreto Sant'Anna
Browse files

Fixed server ls

parent 963bc338
No related branches found
No related tags found
1 merge request!1Lento
......@@ -74,7 +74,7 @@ int Protocol::setData(vector<BYTE> data, int type){
msg.data = subvector;
if(size < MINSIZE){
BYTE zero = 0x00;
msg.data.insert(msg.data.begin(), MINSIZE-size, zero);
msg.data.insert(msg.data.end(), MINSIZE-size, zero);
size = MINSIZE;
}
msg.size = bitset<SIZE_S>(size);
......
......@@ -16,6 +16,7 @@ void cd(string path){
string ls(string args){
string output;
args += " 2>&1";
FILE *lsOut = popen(args.c_str(), "r");
if(!lsOut){
throw "Couldn't execute ls";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment