home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / sys / next / sysadmin / 4946 < prev    next >
Encoding:
Text File  |  1992-08-31  |  2.2 KB  |  89 lines

  1. Path: sparky!uunet!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!szatezal
  2. From: szatezal@magnus.acs.ohio-state.edu (Shane M Zatezalo)
  3. Newsgroups: comp.sys.next.sysadmin
  4. Subject: NNTP Compiling - type mismatch in initialization
  5. Message-ID: <1992Aug31.152659.15528@magnus.acs.ohio-state.edu>
  6. Date: 31 Aug 92 15:26:59 GMT
  7. Sender: news@magnus.acs.ohio-state.edu
  8. Organization: The Ohio State University
  9. Lines: 77
  10. Nntp-Posting-Host: magnusug.magnus.acs.ohio-state.edu
  11.  
  12. I'm trying to compile NNTP, and when the compiler is doing the file "misc.c"
  13. it bombs out with this:
  14.  
  15. (btw... thanks to Tim Gurbick for helping me with my first problem!)
  16.  
  17.  
  18. >make server
  19. cd server; make  "LIBS=-ldbm" "CFLAGS=-O "
  20. cc -O  -c misc.c
  21. misc.c:955: type mismatch in initialization
  22. misc.c:955: type mismatch in initialization
  23.  
  24.  
  25. Here is the code from the file where it seems to be boming: (approximately)
  26.  
  27. /*
  28. **  GETLA -- get the current load average
  29. **
  30. **      This code stolen from la.c. (And subsequently stolen from sendmail,
  31. **              conf.c for nntpd.)
  32. **
  33. **      Parameters:
  34. **              none.
  35. **
  36. **      Returns:
  37. **              The current load average as an integer.
  38. **
  39. **      Side Effects:
  40. **              none.
  41. */
  42.  
  43. #ifdef USG
  44. getla()
  45. {
  46.         return(0);
  47. }
  48. #else
  49. #include <nlist.h>
  50. #include <sys/ioctl.h>
  51.  
  52. struct  nlist Nl[] =
  53. {
  54.         { "_avenrun" },
  55. #define X_AVENRUN       0
  56.         { 0 },
  57. };
  58.  
  59. getla()
  60. {
  61.         static int kmem = -1;
  62. # ifdef FSCALE
  63.         long avenrun[3];
  64. # else
  65.         double avenrun[3];
  66. # endif
  67.         extern off_t lseek();
  68.  
  69.         if (kmem < 0)
  70.         {
  71.                 kmem = open("/dev/kmem", 0, 0);
  72.                 if (kmem < 0)
  73.                         return (-1);
  74.                 (void) ioctl(kmem, (int) FIOCLEX, (char *) 0);
  75.                 nlist("/vmunix", Nl);
  76.                 if (Nl[0].n_type == 0)
  77.                         return (-1);
  78.         }
  79.  
  80.  
  81.  
  82.  
  83. any ideas?
  84.  
  85.  _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
  86. :   Shane M. Zatezalo         : i-net> szatezal@magnus.acs.ohio-state.edu :
  87. :   CIS Eng Ohio State        : NeXTMail>  shane@kiwi.shws.ohio-state.edu :
  88. :GS:::: Apple II forever!! ::::::GO BUCKS!::::::: Play Lacrosse! :::::::GS:
  89.