Skip to content

Commit

Permalink
src/arch.c :use Excutable file name to TargetName
Browse files Browse the repository at this point in the history
  • Loading branch information
yuk7 committed Oct 19, 2017
1 parent 6711935 commit 19e1c92
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions src/arch.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,17 @@ typedef int (WINAPI *REGISTERDISTRIBUTION)(PCWSTR,PCWSTR);
wchar_t *GetLxUID(wchar_t *DistributionName,wchar_t *LxUID);


int main()
int main(int argc,char *argv[])
{
//Set Target Name
wchar_t TargetName[] = L"Arch";
//Get file name of exe
char efpath[300];
if(GetModuleFileName(NULL,efpath,300) == 0)
return 1;
char efName[50];
_splitpath(efpath,NULL,NULL,efName,NULL);

wchar_t TargetName[30];
mbstowcs_s(NULL,TargetName,30,efName,_TRUNCATE);


HMODULE hmod;
Expand Down

0 comments on commit 19e1c92

Please sign in to comment.