From aa8b8043367f7a0e4fd29146d3df83ee8866aee2 Mon Sep 17 00:00:00 2001 From: phk Date: Sun, 9 May 1999 10:25:30 +0000 Subject: Yet another place which knew too much. Still not sure how much good this does in the end. --- sys/compat/linux/linux_stats.c | 4 ++-- sys/i386/linux/linux_stats.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'sys') diff --git a/sys/compat/linux/linux_stats.c b/sys/compat/linux/linux_stats.c index dc9090b..8e9db81 100644 --- a/sys/compat/linux/linux_stats.c +++ b/sys/compat/linux/linux_stats.c @@ -25,7 +25,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: linux_stats.c,v 1.9 1997/11/06 19:29:04 phk Exp $ + * $Id: linux_stats.c,v 1.10 1999/05/06 18:44:28 peter Exp $ */ #include @@ -74,7 +74,7 @@ newstat_copyout(struct stat *buf, void *ubuf) { struct linux_newstat tbuf; - tbuf.stat_dev = (buf->st_dev & 0xff) | ((buf->st_dev & 0xff00)<<10); + tbuf.stat_dev = minor(buf->st_dev) | (major(buf->st_dev) << 10); tbuf.stat_ino = buf->st_ino; tbuf.stat_mode = buf->st_mode; tbuf.stat_nlink = buf->st_nlink; diff --git a/sys/i386/linux/linux_stats.c b/sys/i386/linux/linux_stats.c index dc9090b..8e9db81 100644 --- a/sys/i386/linux/linux_stats.c +++ b/sys/i386/linux/linux_stats.c @@ -25,7 +25,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: linux_stats.c,v 1.9 1997/11/06 19:29:04 phk Exp $ + * $Id: linux_stats.c,v 1.10 1999/05/06 18:44:28 peter Exp $ */ #include @@ -74,7 +74,7 @@ newstat_copyout(struct stat *buf, void *ubuf) { struct linux_newstat tbuf; - tbuf.stat_dev = (buf->st_dev & 0xff) | ((buf->st_dev & 0xff00)<<10); + tbuf.stat_dev = minor(buf->st_dev) | (major(buf->st_dev) << 10); tbuf.stat_ino = buf->st_ino; tbuf.stat_mode = buf->st_mode; tbuf.stat_nlink = buf->st_nlink; -- cgit v1.1