Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Feb 2002 15:19:38 +0200 (EET)
From:      Giorgos Keramidas <keramida@freebsd.org>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   ports/35045: unbreak editors/joe WRT getcontext()
Message-ID:  <200202171319.g1HDJcb02878@hades.hell.gr>

next in thread | raw e-mail | index | archive | help

>Number:         35045
>Category:       ports
>Synopsis:       unbreak editors/joe WRT getcontext()
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun Feb 17 07:30:02 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Giorgos Keramidas
>Release:        FreeBSD 5.0-CURRENT i386
>Organization:
>Environment:

	FreeBSD hades.hell.gr 5.0-CURRENT FreeBSD 5.0-CURRENT #0:
	Thu Feb 7 22:51:16 EET 2002
	sysop@hades.hell.gr:/usr/obj/usr/src/sys/GENERIC i386

>Description:

	The editors/joe port fails to build on the version of -CURRENT
	shown above, because getcontext() is used by joe as a function
	name.

>How-To-Repeat:

	Rebuild joe-2.8_4 on a snapshot of CURRENT after Feb 7.

>Fix:

	The following patch changes getcontext() in the source of joe to
	getnamecontext().  This allows joe to build again on my machine :)

--- bw.c.orig	Sun Feb 17 15:07:36 2002
+++ bw.c	Sun Feb 17 15:06:04 2002
@@ -735,5 +735,5 @@
  {
  rmkbd(window->kbd);
- window->kbd=mkkbd(getcontext(w->o.context));
+ window->kbd=mkkbd(getnamecontext(w->o.context));
  } 
 w->top->xcol=0; w->cursor->xcol=0;
--- rc.c.orig	Sun Feb 17 15:07:36 2002
+++ rc.c	Sun Feb 17 15:06:17 2002
@@ -30,5 +30,5 @@
  */
 
-KMAP *getcontext(name)
+KMAP *getnamecontext(name)
 char *name;
  {
@@ -741,5 +741,5 @@
        for(c=x;!cwhitef(buf[c]);++c);
        buf[c]=0;
-       if(c!=x) kcpy(context,getcontext(buf+x));
+       if(c!=x) kcpy(context,getnamecontext(buf+x));
        else
         {
@@ -790,5 +790,5 @@
        fprintf(stderr,"\n%s %d: No context selected for :delete",name,line);
        }
-     else context=getcontext(buf+1);
+     else context=getnamecontext(buf+1);
     else
      {
--- rc.h.orig	Sun Feb 17 15:07:36 2002
+++ rc.h	Sun Feb 17 15:06:31 2002
@@ -35,9 +35,9 @@
 void setopt();
 
-/* KMAP *getcontext(char *name);
+/* KMAP *getnamecontext(char *name);
  * Find and return the KMAP for a given context name.  If none is found, an
  * empty kmap is created, bound to the context name, and returned.
  */
-KMAP *getcontext();
+KMAP *getnamecontext();
 
 /* int procrc(char *name);  Process an rc file
--- w.c.orig	Sun Feb 17 15:07:36 2002
+++ w.c	Sun Feb 17 15:06:38 2002
@@ -595,5 +595,5 @@
 
  /* Create new keyboard handler for window */
- if(watom->context) new->kbd=mkkbd(getcontext(watom->context));
+ if(watom->context) new->kbd=mkkbd(getnamecontext(watom->context));
  else new->kbd=0;
 
>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200202171319.g1HDJcb02878>