summaryrefslogtreecommitdiff
path: root/editors/mg2a/patches/patch-ag
blob: 7214ef82bf0e4dc5c847bc873806d99c4ede4088 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
$NetBSD: patch-ag,v 1.2 2000/07/10 18:26:54 tron Exp $

--- dir.c.orig	Sun Jul  3 10:50:52 1988
+++ dir.c	Wed May 31 16:36:32 2000
@@ -11,6 +11,7 @@
 #ifndef	getwd			/* may be a #define */
 char	*getwd();
 #endif
+char	*getcwd();               /* refling added this */
 char	*wdir;
 static char cwd[NFILEN];
 
@@ -19,7 +20,8 @@
  */
 dirinit()
 {
-	if (!(wdir = getwd(cwd)))
+/*	if (!(wdir = getwd(cwd)))  refling was here */
+	if (!(wdir = getcwd(cwd, NFILEN)))
 		panic("Can't get current directory!");
 }
 
@@ -40,7 +42,8 @@
 		ewprintf("Can't change dir to %s", bufc);
 		return(FALSE);
 	} else {
-		if (!(wdir = getwd(cwd)))
+/*		if (!(wdir = getwd(cwd)))   refling was here */
+		if (!(wdir = getcwd(cwd, NFILEN)))
 			panic("Can't get current directory!");
 		ewprintf("Current directory is now %s", wdir);
 		return(TRUE);