Category : OS/2 Files
Archive   : EMXTST8F.ZIP
Filename : OS2TEST.C

 
Output of file : OS2TEST.C contained in archive : EMXTST8F.ZIP
/* os2test.c (emx+gcc) */

#include
#include
#include

char upper_case[] = "upper case";

int main (void)
{
COUNTRYCODE cc;
ULONG aul[100];
ULONG cb, i, rc;
CHAR ach[256];

cc.country = 0;
cc.codepage = 0;
if ((rc = DosMapCase (strlen (upper_case), &cc, upper_case)) != 0)
printf ("DosMapCase failed: %lu\n", rc);
else
printf ("DosMapCase: %s\n", upper_case);
if ((rc = DosQueryCp (sizeof (aul), aul, &cb)) != 0)
printf ("DosQueryCp failed: %lu\n", rc);
else
{
printf ("Code pages:");
for (i = 0; i < cb / sizeof (aul[0]); ++i)
printf (" %lu", aul[i]);
putchar ('\n');
}
if ((rc = DosQueryCollate (sizeof (ach), &cc, ach, &cb)) != 0)
printf ("DosQueryCollate failed: %lu\n", rc);
else
{
printf ("DosQueryCollate:");
for (i = 0; i < cb / sizeof (ach[0]); ++i)
printf (" %d", (int)(UCHAR)ach[i]);
putchar ('\n');
}
return (0);
}


  3 Responses to “Category : OS/2 Files
Archive   : EMXTST8F.ZIP
Filename : OS2TEST.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/