Moving from c9 to Linux virtualbox, runtime error



I couldn’t find any answer for my problem anywhere. I hope this is not a silly question.
I wrote a program in c on, it is working flawlessy: it compiles and runs with no problem at all.
Due to an internet mulfunction now I cannot rely on
Anyways, I downloaded the code (the c code, not the compiled file), I compiled it on my Ubuntu VirtualBox machine and no problem, just to be a 100% sure I also made a “chmod +x” on the compiled file. But when it comes to running the compiled file, it gives an error generated by this piece of code:

    if(read(mypipe[number*2],buff,sizeof(buff)) == -1){
        perror("read 1");

this wasn’t happening on, the same code (copied & pasted) on is not printing this error.
I’m really stuck on this, please help me :’(
INFO: On I’m using a machine running the blank Ubuntu


what error does it print?