MCPcopy Create free account
hub / github.com/cgsecurity/testdisk / xml_set_command_line

Function xml_set_command_line

src/dfxml.c:88–107  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

86}
87
88void xml_set_command_line(const int argc, char **argv)
89{
90 int i;
91 int len=argc;
92 if(command_line!=NULL)
93 return ;
94 /* Capture the command line */
95 for(i=0; i<argc; i++)
96 {
97 len+=strlen(argv[i]);
98 }
99 command_line = (char *)MALLOC(len);
100 command_line[0]='\0';
101 for(i=0; i<argc; i++)
102 {
103 if(i>0)
104 strcat(command_line," ");
105 strcat(command_line, argv[i]);
106 }
107}
108
109void xml_clear_command_line(void)
110{

Callers 1

mainFunction · 0.85

Calls 1

MALLOCFunction · 0.85

Tested by

no test coverage detected