home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / gnu / utils / bug / 2052 < prev    next >
Encoding:
Text File  |  1992-11-12  |  1.7 KB  |  48 lines

  1. Newsgroups: gnu.utils.bug
  2. Path: sparky!uunet!convex!darwin.sura.net!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!sisug.sisu.SE!uddeborg
  3. From: uddeborg@sisug.sisu.SE (Goeran Uddeborg)
  4. Subject: finger 1.37 special targets
  5. Message-ID: <199211121602.AA02270@albert.sisu.se>
  6. Sender: gnulists@ai.mit.edu
  7. Organization: GNUs Not Usenet
  8. Distribution: gnu
  9. Date: Thu, 12 Nov 1992 18:02:54 GMT
  10. Approved: bug-gnu-utils@prep.ai.mit.edu
  11. Lines: 35
  12.  
  13. I tried to make a new special target, with different behaviour for
  14. long and short fingering.  I then discovered that I always got the
  15. short answer, independent of the flags given.  I traced this down to
  16. in.fingerd.c where a check is made to look for special target scripts
  17. with an s- or x- prefix.  This attempt is made irrespectively of the
  18. value of the is_long_finger flag, and before the special code for long
  19. fingers are executed.  I solved the problem by moving the test later
  20. in the code, but I'm not sure if may I have introduced some other
  21. problem with this fix.  Anyway, this is how I made it:
  22.  
  23. --- in.fingerd.c.org    Tue Oct 27 04:14:19 1992
  24. +++ in.fingerd.c    Thu Nov 12 16:34:33 1992
  25. @@ -371,10 +371,6 @@
  26.        return;
  27.      }
  28.  
  29. -  if (maybe_special_target (user, stream, 's')
  30. -      || maybe_special_target (user, stream, 'x'))
  31. -    return;
  32. -
  33.    /* Is this a local finger?  If so, just call the local client finger
  34.       daemon to get packets, and print them out. */
  35.    if (xstricmp (user, ".local") == 0)
  36. @@ -453,6 +449,10 @@
  37.  
  38.        return;
  39.      }
  40. +
  41. +  if (maybe_special_target (user, stream, 's')
  42. +      || maybe_special_target (user, stream, 'x'))
  43. +    return;
  44.  
  45.    /* If the user wants to know about free machines then look the information
  46.       up in the database kept on the availability of hosts.  Print statistics
  47.  
  48.