Category : Recently Uploaded Files
Archive   : SNIP9503.ZIP
Filename : CCOMCALL.C

 
Output of file : CCOMCALL.C contained in archive : SNIP9503.ZIP
/*
** Call undocumented Int 2Eh to invoke COMMAND.COM
**
** demo by Bob Stout
**
** NOTES: Dangerous code - will abort batch files in progress and
** occasionally have other undesirable effects.
**
** Requires INT2E.ASM
*/

#include
#include

extern void _Int_2E(char *);

void C_Com_Call(char *string)
{
char *buf;

buf = (char *)malloc(strlen(string) + 3);
strcat(strcpy(&buf[1], string), "\r");
buf[0] = (char)strlen(&buf[1]);
_Int_2E(buf);
free(buf);
}

#ifdef TEST

main(int argc, char *argv[])
{
C_Com_Call(argv[1]);
return 0;
}

#endif



  3 Responses to “Category : Recently Uploaded Files
Archive   : SNIP9503.ZIP
Filename : CCOMCALL.C

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/