home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / unix / wizards / 3705 < prev    next >
Encoding:
Text File  |  1992-08-27  |  1.1 KB  |  41 lines

  1. Newsgroups: comp.unix.wizards
  2. Path: sparky!uunet!mcsun!sunic!ericom!eos.ericsson.se!etxmesa
  3. From: etxmesa@eos.ericsson.se (Michael Salmon)
  4. Subject: Re: A few UNIX questions
  5. Message-ID: <1992Aug27.132544.10264@ericsson.se>
  6. Sender: news@ericsson.se
  7. Nntp-Posting-Host: eos6c02.ericsson.se
  8. Reply-To: etxmesa@eos.ericsson.se (Michael Salmon)
  9. Organization: Ericsson Telecom AB
  10. References: <1992Aug26.081414.6932@sniap.mchp.sni.de> <169@sc.sni.ie>
  11. Date: Thu, 27 Aug 1992 13:25:44 GMT
  12. Lines: 27
  13.  
  14. In article <169@sc.sni.ie>, 
  15. bsullivn@sc.sni.ie (Bryan O'Sullivan) writes:
  16. |> 
  17. |> 
  18. |> frank@D012S436.sniap.mchp.sni.de writes:
  19. |> 
  20. |> ::Because lseek() needs to be able to return -1 on error, and not have it
  21. |> ::look like a valid file offset.
  22. |> 
  23. |> :Umm, and a *signed* file size helps, does it?
  24. |> 
  25. |> RTFM.  Lseek(2) returns the current position in the file, or -1 on
  26. |> error.  If you can think of any way to produce -1 by using unsigned
  27. |> values, well ...
  28.  
  29. ~0 works for me.
  30.  
  31. -- 
  32.  
  33. Michael Salmon
  34.  
  35. #include    <standard.disclaimer>
  36. #include    <witty.saying>
  37. #include    <fancy.pseudo.graphics>
  38.  
  39. Ericsson Telecom AB
  40. Stockholm
  41.