実際に動くかどうかはともかく、
これのどこがおかしいか分からないというのはやばいと思うが

#include<stdio.h>
void xcopy(char *to,char *from){
 int i=0,j=0;
 while(from[i]!=NULL) i++; //まあ動くがNULL→'\0'
 while(from[i-1]!=NULL){
//from[-1]が0である保証はない(ちゃんと止まる保証は無い)
  to[j]=from[i-1];
  j++;
 i--;
 }
 to[j]=NULL;
}
main(){
char *to,*from; //領域確保しろよ
scanf("%s",from);
xcopy(to,from);
printf("%s",to);
}