<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent changes to 3: Timeout possibility forSshShell.Expect</title><link href="https://sourceforge.net/p/sharpssh/feature-requests/3/" rel="alternate"/><link href="https://sourceforge.net/p/sharpssh/feature-requests/3/feed.atom" rel="self"/><id>https://sourceforge.net/p/sharpssh/feature-requests/3/</id><updated>2013-04-17T12:14:02Z</updated><subtitle>Recent changes to 3: Timeout possibility forSshShell.Expect</subtitle><entry><title>Timeout possibility forSshShell.Expect</title><link href="https://sourceforge.net/p/sharpssh/feature-requests/3/" rel="alternate"/><published>2013-04-17T12:14:02Z</published><updated>2013-04-17T12:14:02Z</updated><author><name>polarlightning</name><uri>https://sourceforge.net/u/polarlightning/</uri></author><id>https://sourceforge.netd50edec4c55a493b0535480f41f3819fa519a0ed</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I would find it very useful and aligned with common patterns with similar things that Expect(..) function would have timeout parameter (timeout in milliseconds). &lt;br /&gt;
"Whenever you are expecting something that you cannot be 100% sure of, it might happen that it never happens what you are waiting for".&lt;/p&gt;
&lt;p&gt;I think there is a generic need for such, but I can list two specific cases additionally:&lt;br /&gt;
- when executing commands after one another and some of those are optional,&lt;br /&gt;
you cannot know for each command  if you should first expect for a command prompt or not&lt;br /&gt;
in a common command-handling method which would take any command string as a parameter&lt;br /&gt;
and return the output of the command as a string.&lt;br /&gt;
Waiting for command prompt for some time (timeout) would help the situation.&lt;/p&gt;
&lt;p&gt;- When executing a command to configure the IP-interface of the device, you will loose&lt;br /&gt;
connection with the device in the middle of command. In that case if you are waiting&lt;br /&gt;
for some string and have no timeout-failure option, you are in troubles (or have to use dirty methods).&lt;/p&gt;
&lt;p&gt;Thanks for considering!&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>