[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Spawn Pipes





Any other unix 5.3 users out there have trouble reading from file units spawned
as pipes to a command?  Try this procedure:

pro simp
   cmd='ls'
   spawn,unit=un,cmd
   line=''
   while 1 do begin
      readf,un,line
      print,'GOT: ',line
   endwhile 
end

For me, almost every run results in an IDL segfault, though occassionally it
will work.

JD

-- 
 J.D. Smith                             |*|      WORK: (607) 255-5842    
 Cornell University Dept. of Astronomy  |*|            (607) 255-6263
 304 Space Sciences Bldg.               |*|       FAX: (607) 255-5875 
 Ithaca, NY 14853                       |*|