X-Git-Url: https://git.cameronkatri.com/mandoc.git/blobdiff_plain/ea3a546595c994f7d63049af16eecab1660ef4fa..a86259b51b74480e80c3daacead5b638d4cf0206:/soelim.c?ds=sidebyside

diff --git a/soelim.c b/soelim.c
index c1fa4adb..3ef30820 100644
--- a/soelim.c
+++ b/soelim.c
@@ -1,4 +1,4 @@
-/*	$Id: soelim.c,v 1.2 2015/05/20 22:22:59 schwarze Exp $	*/
+/*	$Id: soelim.c,v 1.5 2015/11/07 14:22:29 schwarze Exp $	*/
 /*
  * Copyright (c) 2014 Baptiste Daroussin <bapt@FreeBSD.org>
  * All rights reserved.
@@ -24,12 +24,15 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
+#include "config.h"
 
-#include <sys/param.h>
 #include <sys/types.h>
 
 #include <ctype.h>
+#if HAVE_ERR
 #include <err.h>
+#endif
+#include <limits.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -57,7 +60,7 @@ static FILE *
 soelim_fopen(const char *name)
 {
 	FILE *f;
-	char path[MAXPATHLEN];
+	char path[PATH_MAX];
 	size_t i;
 
 	if (strcmp(name, "-") == 0)