版权声明:墨痕诉清风 https://blog.csdn.net/u012206617/article/details/84841328
FILE* fp = fopen(strFileNameDes.c_str(), "w");
string strFourBlanks = " ";
string strEightBlanks = " ";
fprintf(fp,"%s\n", "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>");
fprintf(fp,"%s\n", "<result>");
fprintf(fp,"%s%s\n", strEightBlanks.c_str(), "</viruss>");
fclose(fp);