#include "deftype.h"

unchar *jstrchange(unchar *str,unchar *str2,int ch1,int ch2)
{
int c;
unchar *s;
	s=str2;
	while ((c=*str++)!=0) {
		if (check_kanji1(c)) c=(c<<8)|*str++;
		if (c==ch1) c=ch2;
		if (c>=256) {
			*s++=c/256;
			c&=0xff;
		}
		*s++=c;
	}
	return(str2);
}
