Thread (49 messages) 49 messages, 12 authors, 2014-06-03

Re: [RFC 11/32] xfs: convert to struct inode_time

From: Theodore Ts'o <tytso@mit.edu>
Date: 2014-06-02 23:32:12
Also in: linux-arch, linux-fsdevel, linux-nfs, lkml

On Mon, Jun 02, 2014 at 03:32:35PM -0700, H. Peter Anvin wrote:
On 06/02/2014 03:29 PM, Theodore Ts'o wrote:
quoted
And since we are already returning (time_t) -1 in some cases, we might
as well try to make things a bit more formal.
Are we?  I am not aware of *Linux* actually using that.
Linux's time(2) can return (time_t) -1 and set errno to EFAULT, per
the Posix specification:

SYSCALL_DEFINE1(time, time_t __user *, tloc)
{
	time_t i = get_seconds();

	if (tloc) {
		if (put_user(i,tloc))
			return -EFAULT;
	}
	force_successful_syscall_return();
	return i;
}

Cheers,

						- Ted

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help