plan9port

fork of plan9port with libvec, libstr and libsdb
Log | Files | Refs | README | LICENSE

ndbconcatenate.c (259B)


      1 #include <u.h>
      2 #include <libc.h>
      3 #include <bio.h>
      4 #include <ndb.h>
      5 
      6 /* concatenate two tuples */
      7 Ndbtuple*
      8 ndbconcatenate(Ndbtuple *a, Ndbtuple *b)
      9 {
     10 	Ndbtuple *t;
     11 
     12 	if(a == nil)
     13 		return b;
     14 	for(t = a; t->entry; t = t->entry)
     15 		;
     16 	t->entry = b;
     17 	return a;
     18 }