我正在一个(乌图精确的)支气系统,我想从C的扼杀中排除主要特征(推器)。 我认为,下面的法典正在我先前的安装工作(Uubuntu一ric),但现在我发现这部法律没有再奏效(意思是,这是通用的UTF-8型特征的一部简略版本):
#include <math.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
int main()
{
int nbytes = 10000;
char *my_line, *my_char;
my_line = (char *)malloc((nbytes + 1)*sizeof(char));
strcpy(my_line," interface(quiet=true):");
printf("MY_LINE_ORIG=%s
",my_line);
while((my_char=strchr(my_line,9))!=NULL){
strcpy(my_char, my_char+1);
}
printf("MY_LINE=%s
",my_line);
return 0;
}
我
gcc -o removetab removetab.c
When executing removetab I get
MY_LINE_ORIG= interface(quiet=true):
MY_LINE=interfae(quiet==true):
Note the dublication of "=" and the missing "c"! Whats wrong or how can I achieve this alternatively. The code should support UTF-8 strings.