[ create a new paste ] login | about

Link: http://codepad.org/h3lmZBmN    [ raw code | output | fork ]

C, pasted on Aug 30:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include <stdio.h>

int main(void)
{
	FILE *f;

	f = fopen("/home/crobbins/", "r");
	if (f) {
		int c;
		if ((c = fgetc(f)) != EOF)
			printf("Ok\n");
		else
			perror("Could not read: ");

		fclose(f);
	} else
		perror("Error: ");

	return 0;
}


Output:
1
Disallowed system call: SYS_dup


Create a new paste based on this one


Comments: