home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / unix / question / 10125 < prev    next >
Encoding:
Text File  |  1992-08-17  |  1.3 KB  |  47 lines

  1. Path: sparky!uunet!gatech!psuvax1!rutgers!njitgw.njit.edu!hertz.njit.edu!cxk6819
  2. From: cxk6819@hertz.njit.edu (K. Chandrakanth)
  3. Newsgroups: comp.unix.questions
  4. Subject: problem with vi..
  5. Message-ID: <1992Aug17.155121.21926@njitgw.njit.edu>
  6. Date: 17 Aug 92 15:51:21 GMT
  7. Sender: news@njit.edu
  8. Organization: New Jersey Institute of Technology, Newark, N.J.
  9. Lines: 34
  10. Originator: cxk6819@hertz.njit.edu
  11. Nntp-Posting-Host: hertz.njit.edu
  12.  
  13. Dear netters,
  14.      I have a sparc workstation 2.
  15. I mounted the floppy drive and copied few files from the floppy. But
  16. when I viewed through vi I happened to see ^M at the end of each line.
  17. When I cat the file it looks normal. Will some one tell me the reason
  18. for this. If possible please send me a shell script or small c program
  19. to remove this. I am enclosing a sample of the file.
  20.  
  21.     But when I compile the file it works fine. The control characters
  22. are really irritating. So help me.
  23.  
  24. struct employee {^M
  25.     e_type typer;^M
  26.     employee *next;^M
  27.     char name[20];^M
  28.     short department;^M
  29. };^M
  30. ^M
  31. struct manager:employee {^M
  32.         employee* group;^M
  33.         short level;^M
  34. };^M
  35. void print_emp(employee *);^M
  36. void f(employee *);^M
  37. void print_emp(employee *e)^M
  38. {^M
  39.  
  40. Please email to me. Thanks in advance...
  41.  
  42. cxk6819@hertz.njit.edu
  43.  
  44. -- 
  45. god's theorem:
  46.         those who sow in tears will reap in joy.
  47.