File:  [truecrypt] / truecrypt / linux / common / platform.c
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 16:43:12 2018 UTC (8 years, 3 months ago) by root
Branches: drWhax, MAIN
CVS tags: v4_3a, v4_3, v4_2a, v4_2, v4_1, v4_0, HEAD
4.0

#include <stdlib.h>
#include <stdio.h>

char *GetType (int size)
{
	if (size == sizeof (char)) return "char";
	if (size == sizeof (short)) return "short";
	if (size == sizeof (int)) return "int";
	if (size == sizeof (long)) return "long";
	if (size == sizeof (long long)) return "long long";

	fprintf (stderr, "Error: No type available for %d bytes\n", size);
	exit (1);
}

int main(int argc, char **argv)
{
	printf ("TYPES := -D__int8=\"%s\" -D__int16=\"%s\" -D__int32=\"%s\" -D__int64=\"%s\"\n",
		GetType (1), GetType (2), GetType (4), GetType (8));

	exit (0);
}

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.