<div dir="ltr">Nevermind, figured out. I forgot < redirects to stdin so just had to use scanf if no more command line arguments.</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Dec 6, 2013 at 11:09 PM, Tejas Nadkarni <span dir="ltr"><<a href="mailto:tnadkarn@stevens.edu" target="_blank">tnadkarn@stevens.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I'm trying to figure out how to read in the piped files with getopt/argv.<div><br></div><div>i.e. ./aed -e -p secret <input</div>
<div><br></div><div>How do I read in the input? I tried using argv[optind] or even argv[argc] and I get null. </div>
<div><br></div><div>Any tips on how to read this in? It works fine if you enter text at the command line but I can't get the piped files to work. Output seems to work, just need help with the input. </div><div><br></div>
<div>Thanks for help</div></div>
</blockquote></div><br></div>