Style inquistion for util and some tools.
This commit is contained in:
@@ -3,18 +3,23 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "../util.h"
|
||||
|
||||
void
|
||||
apathmax(char **p, long *size)
|
||||
{
|
||||
errno = 0;
|
||||
|
||||
if((*size = pathconf(".", _PC_PATH_MAX)) == -1) {
|
||||
if(errno == 0)
|
||||
if(errno == 0) {
|
||||
*size = BUFSIZ;
|
||||
else
|
||||
} else {
|
||||
eprintf("pathconf:");
|
||||
}
|
||||
}
|
||||
|
||||
if(!(*p = malloc(*size)))
|
||||
eprintf("malloc:");
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user