<div dir="ltr">getpwuid</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, May 13, 2013 at 11:46 AM, Rick Troth <span dir="ltr"><<a href="mailto:rmt@casita.net" target="_blank">rmt@casita.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">from C?<br>
<div class="HOEnZb"><div class="h5"><br>
On Mon, May 13, 2013 at 12:47 PM, Jeff Frontz <<a href="mailto:jeff.frontz@gmail.com">jeff.frontz@gmail.com</a>> wrote:<br>
> I use "id -un". Works on linux and MacOS (under ksh).<br>
><br>
><br>
><br>
><br>
> On Mon, May 13, 2013 at 11:58 AM, Rick Troth <<a href="mailto:rmt@casita.net">rmt@casita.net</a>> wrote:<br>
>><br>
>> There must be two dozen ways to extract the username.<br>
>> I've coded two or three in the past. Before I do it again, what would<br>
>> y'all recommend?<br>
>><br>
>> In this case, I need the username, not the UID.<br>
>> I'm writing a jail that will run another program for which the<br>
>> username is one of the arguments.<br>
>><br>
>> --<br>
>> -- R; <><<br>
>> _______________________________________________<br>
>> colug-432 mailing list<br>
>> <a href="mailto:colug-432@colug.net">colug-432@colug.net</a><br>
>> <a href="http://lists.colug.net/mailman/listinfo/colug-432" target="_blank">http://lists.colug.net/mailman/listinfo/colug-432</a><br>
><br>
><br>
><br>
> _______________________________________________<br>
> colug-432 mailing list<br>
> <a href="mailto:colug-432@colug.net">colug-432@colug.net</a><br>
> <a href="http://lists.colug.net/mailman/listinfo/colug-432" target="_blank">http://lists.colug.net/mailman/listinfo/colug-432</a><br>
><br>
<br>
<br>
<br>
--<br>
-- R; <><<br>
_______________________________________________<br>
colug-432 mailing list<br>
<a href="mailto:colug-432@colug.net">colug-432@colug.net</a><br>
<a href="http://lists.colug.net/mailman/listinfo/colug-432" target="_blank">http://lists.colug.net/mailman/listinfo/colug-432</a><br>
</div></div></blockquote></div><br></div>