• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

java gui freezes after executing action event

 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i have a java GUI that when a menu item is clicked it will use the runtime.exec method to execute a process and bring up a report. It does that just fine but then it suddenly freezes up and i cannot access anything for a while. I cannot even scroll through the report to analyse the data. The report is shown on an xterm and i am wondering why i cannot do anything after the report is created. 1. My java code that executes the csh script




When i comment out my error checking code everything works fine and the program doesn't freeze up. It has something to do with the inputsream reading an erro message. This is the portion of code that i comment out



it is somehow hanging up when this happens and i dont know why. Can somebody help because i definately need this error checking portion incase anything goes wrong. I have narrowed it down to the while loop. Everything else works normally but as soon as i put the while loop to read from the buffer it freezes up again. Somehow the subprocess is taking too long to temrinate. Here is the code that is not working


Essentially there are no errors in the script because it produces the report so the geterrorstream should be NULL causing the while loop to be ignored but it is not? It seems like it is reading something for a while(hence freezes up).


 
reply
    Bookmark Topic Watch Topic
  • New Topic