Andrej, Pretty code, but I am not sure how it does the business. ((I particularly like the do { ... } while (0); - should we run a competition for the best explanation of that line ?)) I assume 48 is the minimum number of bytes that can be in a valid directory (which contains . and ..), unless presumably it is /, because /.. would be a whole new concept.