Ticket #1171: realpath_bug.c

File realpath_bug.c, 257 bytes (added by Tim Kosse, 13 years ago)

Minimal sample to reproduce problem

Line 
1#include <stdlib.h>
2#include <limits.h>
3#include <stdio.h>
4
5int main()
6{
7        system("touch foo");
8        link("foo", "bar");
9        unlink("foo");
10
11        char out[PATH_MAX];
12        realpath("bar", out);
13        printf("%s\n", out);
14}
15
16