On 19Jul2014 19:08, JD jd1008@gmail.com wrote:
is there an analog for it in Linux?
More context?
Cheers, Cameron Simpson cs@zip.com.au
On 07/20/14 12:21, Cameron Simpson wrote:
On 19Jul2014 19:08, JD jd1008@gmail.com wrote:
is there an analog for it in Linux?
More context?
Yeah, don't you hate it when people ask a question that causes you to go to google to search for what they are talking about? :-)
I had to look it up to find the FreeBSD man-page.
The leave utility waits until the specified time, then reminds you that you have to leave. You are reminded 5 minutes and 1 minute before the actual time, at the time, and every minute thereafter. When you log off, leave exits just before it would have printed the next message.
The following options are available: hhmm The time of day is in the form hhmm where hh is a time in hours (on a 12 or 24 hour clock), and mm are minutes. All times are converted to a 12 hour clock, and assumed to be in the next 12 hours.
+ If the time is preceded by '+', the alarm will go off in hours and minutes from the current time. If no argument is given, leave prompts with "When do you have to leave?". A reply of newline causes leave to exit, otherwise the reply is assumed to be a time. This form is suitable for inclusion in a .login or .profile.
To get rid of leave you should either log off or use ‘kill -s KILL’ giving its process id.
And then did a kill -9 on my effort. :-)
On 20 July 2014 05:59, Ed Greshko ed.greshko@greshko.com wrote:
On 07/20/14 12:21, Cameron Simpson wrote:
On 19Jul2014 19:08, JD jd1008@gmail.com wrote:
is there an analog for it in Linux?
More context?
I had to look it up to find the FreeBSD man-page.
The leave utility waits until the specified time, then reminds you that you have to leave. You are reminded 5 minutes and 1 minute before the actual time, at the time, and every minute thereafter. When you log off, leave exits just before it would have printed the next message.
It's a very hard command name to search for, but I don't think it's normally packaged for Linux. However it's basically a single file in the BSD tree which seems to compile and run okay under Linux, if you go to: https://svnweb.freebsd.org/base/head/usr.bin/leave/ You can open leave.c then select download. Remove or comment line 42: __FBSDID("$FreeBSD$"); Then compile and enjoy your somewhat annoying reminder utility.
On Sun, Jul 20, 2014 at 5:37 AM, Ian Malone ibmalone@gmail.com wrote:
On 20 July 2014 05:59, Ed Greshko ed.greshko@greshko.com wrote:
On 07/20/14 12:21, Cameron Simpson wrote:
On 19Jul2014 19:08, JD jd1008@gmail.com wrote:
is there an analog for it in Linux?
More context?
I had to look it up to find the FreeBSD man-page.
The leave utility waits until the specified time, then reminds you that
you have to leave. You are reminded 5 minutes and 1 minute before the actual time, at the time, and every minute thereafter. When you log off, leave exits just before it would have printed the next message.
It's a very hard command name to search for, but I don't think it's normally packaged for Linux. However it's basically a single file in the BSD tree which seems to compile and run okay under Linux, if you go to: https://svnweb.freebsd.org/base/head/usr.bin/leave/ You can open leave.c then select download. Remove or comment line 42: __FBSDID("$FreeBSDquot;); Then compile and enjoy your somewhat annoying reminder utility.
Thanx Ian. That version, although dated, is the one that does not use the buffer overflow func calls puts, and fputs. It uses the write system call.
On 20 July 2014 18:44, JD jd1008@gmail.com wrote:
On Sun, Jul 20, 2014 at 5:37 AM, Ian Malone ibmalone@gmail.com wrote:
On 20 July 2014 05:59, Ed Greshko ed.greshko@greshko.com wrote:
On 07/20/14 12:21, Cameron Simpson wrote:
On 19Jul2014 19:08, JD jd1008@gmail.com wrote:
is there an analog for it in Linux?
More context?
I had to look it up to find the FreeBSD man-page.
The leave utility waits until the specified time, then reminds you
that you have to leave. You are reminded 5 minutes and 1 minute before the actual time, at the time, and every minute thereafter. When you log off, leave exits just before it would have printed the next message.
It's a very hard command name to search for, but I don't think it's normally packaged for Linux. However it's basically a single file in the BSD tree which seems to compile and run okay under Linux, if you go to: https://svnweb.freebsd.org/base/head/usr.bin/leave/ You can open leave.c then select download. Remove or comment line 42: __FBSDID("$FreeBSDquot;);
Then compile and enjoy your somewhat annoying reminder utility.
Thanx Ian. That version, although dated, is the one that does not use the buffer overflow func calls puts, and fputs. It uses the write system call.
To be honest I didn't check the code, but figured the most up to date
FreeBSD would be the best choice. NetBSD's original version also uses write and the original commits in 1993/1994 used write. Current NetBSD appears to use puts. I'd add fputs is not a buffer overflow risk. It is potentially a buffer over-read risk and using write in itself does not particularly protect you (indeed, heartbleed was caused by passing an unchecked read length, not an unterminated string). In these cases puts is used on a constant string defined in the source, which is no better or worse than the original approach of #define-ing the string and using sizeof MSG - 1 to get the length for write.
On 07/20/2014 09:16 AM, Patrick O'Callaghan wrote:
is there an analog for it in Linux?
I've been a Unix user since 1975 (yes, really) and I never heard of that, so maybe a little more explanation would be in order.
+1, 1985... maybe the "at" command..