1.0.8.6-1.0.8.7.gz

patches · 2.4 KB · 2010-03-30

Download   « Back to the patches list

Common subdirectories: /usr/home/clay/1.0.8.6/dgd/bin and dgd/bin
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/doc and dgd/doc
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/mud and dgd/mud
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/pkg and dgd/pkg
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src and dgd/src
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/tmp and dgd/tmp
diff -cr /usr/home/clay/1.0.8.6/dgd/doc/Introduction dgd/doc/Introduction
*** /usr/home/clay/1.0.8.6/dgd/doc/Introduction	Thu Sep 29 21:30:07 1994
--- dgd/doc/Introduction	Mon Oct  3 20:42:17 1994
***************
*** 104,112 ****
  
  	Called in an object which has just been cloned, or if it is not a
  	clone, just before a function is called in it for the first time.
! 	The actual name of this function is configurable.  Note that the
! 	driver can call this function even if it is static and in the auto
! 	object.
  
   - in the user object (returned by driver->telnet_connect() or
     driver->binary_connect()):
--- 104,110 ----
  
  	Called in an object which has just been cloned, or if it is not a
  	clone, just before a function is called in it for the first time.
! 	The actual name of this function is configurable.
  
   - in the user object (returned by driver->telnet_connect() or
     driver->binary_connect()):
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/doc/kfun and dgd/doc/kfun
diff -cr /usr/home/clay/1.0.8.6/dgd/src/Changelog dgd/src/Changelog
*** /usr/home/clay/1.0.8.6/dgd/src/Changelog	Thu Sep 29 21:30:08 1994
--- dgd/src/Changelog	Mon Oct  3 20:34:09 1994
***************
*** 721,723 ****
--- 721,726 ----
   - Fixed a bug in telnet subnegotiations.
   - Fixed some other ANSI C pointer problems.
   - The driver can now call static functions in the auto object.
+  - Found a crasher in str.c::str_put() that had eluded me for quite a while.
+  - Undid the static function patch (dumpfile incompatibility and other
+    problems).
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/comp and dgd/src/comp
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/ed and dgd/src/ed
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/host and dgd/src/host
diff -cr /usr/home/clay/1.0.8.6/dgd/src/interpret.c dgd/src/interpret.c
*** /usr/home/clay/1.0.8.6/dgd/src/interpret.c	Thu Sep 29 21:30:11 1994
--- dgd/src/interpret.c	Mon Oct  3 20:40:45 1994
***************
*** 1647,1665 ****
      /* find the function in the symbol table */
      symb = ctrl_symb(ctrl, func);
      if (symb == (dsymbol *) NULL) {
! 	if (call_static && ctrl->ninherits > 1) {
! 	    /* try auto object */
! 	    symb = ctrl_symb(o_control(ctrl->inherits[0].obj), func);
! 	    if (symb == (dsymbol *) NULL) {
! 		/* function doesn't exist in auto object symbol table */
! 		i_pop(nargs);
! 		return FALSE;
! 	    }
! 	} else {
! 	    /* function doesn't exist in symbol table */
! 	    i_pop(nargs);
! 	    return FALSE;
! 	}
      }
  
      ctrl = ctrl->inherits[UCHAR(symb->inherit)].obj->ctrl;
--- 1647,1655 ----
      /* find the function in the symbol table */
      symb = ctrl_symb(ctrl, func);
      if (symb == (dsymbol *) NULL) {
! 	/* function doesn't exist in symbol table */
! 	i_pop(nargs);
! 	return FALSE;
      }
  
      ctrl = ctrl->inherits[UCHAR(symb->inherit)].obj->ctrl;
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/kfun and dgd/src/kfun
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/lex and dgd/src/lex
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/lpc and dgd/src/lpc
diff -cr /usr/home/clay/1.0.8.6/dgd/src/str.c dgd/src/str.c
*** /usr/home/clay/1.0.8.6/dgd/src/str.c	Sat Jul 16 22:32:20 1994
--- dgd/src/str.c	Mon Oct  3 20:04:59 1994
***************
*** 88,96 ****
  
      h = (strh **) ht_lookup(ht, str->text);
      for (;;) {
! 	if (*h == (strh *) NULL || strcmp(str->text, (*h)->str->text) != 0) {
  	    register strh *s;
- 	    hte *next;
  
  	    /*
  	     * Not in the hash table. Make a new entry.
--- 88,100 ----
  
      h = (strh **) ht_lookup(ht, str->text);
      for (;;) {
! 	/*
! 	 * The hasher doesn't handle \0 in strings, and so may not have
! 	 * found the proper string. Follow the hash table chain until
! 	 * the end is reached, or until a match is found using str_cmp().
! 	 */
! 	if (*h == (strh *) NULL) {
  	    register strh *s;
  
  	    /*
  	     * Not in the hash table. Make a new entry.
***************
*** 103,111 ****
  		shlist = l;
  		strhchunksz = 0;
  	    }
- 	    next = (hte *) *h;
  	    s = *h = &shlist->sh[strhchunksz++];
! 	    s->chain.next = next;
  	    s->chain.name = str->text;
  	    s->str = str;
  	    s->index = n;
--- 107,114 ----
  		shlist = l;
  		strhchunksz = 0;
  	    }
  	    s = *h = &shlist->sh[strhchunksz++];
! 	    s->chain.next = (hte *) NULL;
  	    s->chain.name = str->text;
  	    s->str = str;
  	    s->index = n;
diff -cr /usr/home/clay/1.0.8.6/dgd/src/version.h dgd/src/version.h
*** /usr/home/clay/1.0.8.6/dgd/src/version.h	Thu Sep 29 21:30:11 1994
--- dgd/src/version.h	Mon Oct  3 20:04:59 1994
***************
*** 1 ****
! # define VERSION	"1.0.8.6"
--- 1 ----
! # define VERSION	"1.0.8.7"
diff -cr /usr/home/clay/1.0.8.6/dgd/src/comp/control.c dgd/src/comp/control.c
*** /usr/home/clay/1.0.8.6/dgd/src/comp/control.c	Thu Sep 29 21:30:10 1994
--- dgd/src/comp/control.c	Mon Oct  3 20:40:49 1994
***************
*** 501,516 ****
  register control *ctrl;
  {
      register unsigned short n;
-     register object *o;
-     register dsymbol *symb;
  
!     /*
!      * The symbol table rather than the function definition table is
!      * used here.
!      */
!     for (n = ctrl->nsymbols, symb = d_get_symbols(ctrl); n > 0; --n, symb++) {
! 	o = ctrl->inherits[UCHAR(symb->inherit)].obj;
! 	ctrl_funcdef(o->ctrl, UCHAR(symb->index), oh_new(o->chain.name));
      }
  }
  
--- 501,537 ----
  register control *ctrl;
  {
      register unsigned short n;
  
!     if (ctrl->ninherits == 1) {
! 	register dfuncdef *f;
! 	register oh *ohash;
! 
! 	/*
! 	 * For the auto object, add non-private functions from the function
! 	 * definition table.
! 	 */
! 	f = ctrl->funcdefs;
! 	ohash = oh_new(ctrl->inherits->obj->chain.name);
! 	for (n = ctrl->nfuncdefs, f = ctrl->funcdefs + n; n > 0; ) {
! 	    --n;
! 	    --f;
! 	    if (!(f->class & C_PRIVATE)) {
! 		ctrl_funcdef(ctrl, n, ohash);
! 	    }
! 	}
!     } else {
! 	register object *o;
! 	register dsymbol *symb;
! 
! 	/*
! 	 * The symbol table rather than the function definition table is
! 	 * used here.
! 	 */
! 	for (n = ctrl->nsymbols, symb = d_get_symbols(ctrl); n > 0; --n, symb++)
! 	{
! 	    o = ctrl->inherits[UCHAR(symb->inherit)].obj;
! 	    ctrl_funcdef(o->ctrl, UCHAR(symb->index), oh_new(o->chain.name));
! 	}
      }
  }
  
***************
*** 858,863 ****
--- 879,885 ----
  								== C_STATIC) {
  		    /* static function in auto object replaces prototype */
  		    PROTO_CLASS(proto) |= C_LOCAL;
+ 		    --nsymbs;
  		} else if (PROTO_FTYPE(proto2) == T_IMPLICIT &&
  			   (PROTO_CLASS(proto) & C_PRIVATE)) {
  		    /* private function replaces implicit prototype */
***************
*** 922,937 ****
  	/*
  	 * insert the definition before the old one in the hash table
  	 */
!     } else if (!(PROTO_CLASS(proto) & C_PRIVATE)) {
  	/*
  	 * add new prototype to symbol table
  	 */
- 	if (is_auto &&
- 	    (PROTO_CLASS(proto) & (C_STATIC | C_UNDEFINED)) == C_STATIC) {
- 	    /* static functions in auto object are local */
- 	    PROTO_CLASS(proto) |= C_LOCAL;
- 	}
  	nsymbs++;
      }
  
      if (nfdefs == 256) {
--- 944,958 ----
  	/*
  	 * insert the definition before the old one in the hash table
  	 */
!     } else if (!(PROTO_CLASS(proto) & C_PRIVATE) && (!is_auto ||
! 	        (PROTO_CLASS(proto) & (C_STATIC | C_UNDEFINED)) != C_STATIC)) {
  	/*
  	 * add new prototype to symbol table
  	 */
  	nsymbs++;
+     } else {
+ 	/* won't hurt for private functions */
+ 	PROTO_CLASS(proto) |= C_LOCAL;
      }
  
      if (nfdefs == 256) {
***************
*** 1436,1442 ****
      register unsigned short i, n, x, ncoll;
      register dsymbol *symtab, *coll;
  
!     if ((newctrl->nsymbols=nsymbs) == 0) {
  	return;
      }
  
--- 1457,1463 ----
      register unsigned short i, n, x, ncoll;
      register dsymbol *symtab, *coll;
  
!     if ((newctrl->nsymbols = nsymbs) == 0) {
  	return;
      }
  
***************
*** 1466,1476 ****
  
  		if ((f->class & C_PRIVATE) ||
  		    ((f->class & (C_STATIC | C_UNDEFINED)) == C_STATIC &&
! 		     ctrl->ninherits == 1 && ctrl != newctrl)) {
! 		    /*
! 		     * Don't put static auto functions in the symbol table,
! 		     * except in the auto object itself.
! 		     */
  		    continue;
  		}
  		name = d_get_strconst(ctrl, f->inherit, f->index)->text;
--- 1487,1494 ----
  
  		if ((f->class & C_PRIVATE) ||
  		    ((f->class & (C_STATIC | C_UNDEFINED)) == C_STATIC &&
! 		     ctrl->ninherits == 1 &&
! 		     (is_auto || (ctrl->inherits->obj->flags & O_AUTO)))) {
  		    continue;
  		}
  		name = d_get_strconst(ctrl, f->inherit, f->index)->text;
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/host/atarist and dgd/src/host/atarist
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/host/mac and dgd/src/host/mac
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/host/minix68k and dgd/src/host/minix68k
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/host/pc and dgd/src/host/pc
Common subdirectories: /usr/home/clay/1.0.8.6/dgd/src/host/unix and dgd/src/host/unix

Site Stats

Snippets: 1791
Codebases: 571