Win a copy of Murach's MySQL this week in the JDBC and Relational Databases forum!
  • 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

Dealing with runtime.exec() I/) streams

 
Ranch Hand
Posts: 189
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am invoking a communications utility via runtime.exec().



As you can see, I spawn threads to exhaust and print the error and output streams.

If I deliberately screw up the dns name in the pscp command, I do get an error printed out in the streamGobbler thread for PSCP Errors.

But when the pscp command is specified correctly, the process never terminates supposedly because my program is not obtaining and responding to the request for a password.

But this request never shows up in the PSCP output stream?

Any ideas on how I can obtain and respond to the request for a password when invoking pscp in this way?
 
Ranch Hand
Posts: 1923
Scala Postgres Database Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


As you can see, ...


No - that's too bad formatted.
You may edit the post - then perhaps I will spend my time reading it.
If you don't spend your time in writing, why should I in reading?
 
I am mighty! And this is a mighty small ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic