All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jiri Jaburek <jjaburek@redhat.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] syscalls/fcntl34: use struct flock64 on 32bit
Date: Mon, 13 Jun 2016 19:58:25 +0200	[thread overview]
Message-ID: <575EF441.5020506@redhat.com> (raw)
In-Reply-To: <20160613142210.GA354@rei.lan>

On 06/13/16 16:22, Cyril Hrubis wrote:
> Since both manual and glibc examples use struct flock with OFD locks in
> examples and if I compile glibc example for OFD locks[1] on 32bit system
> garbage is passed to kernel syscalls and the program hangs, so I would
> call this glibc/kernel bug.
> 
> I would expect glibc to convert the flock structure to 64 bit one
> silently in this case.

That might not be possible as such "silent" conversion could break
a lot of existing programs that rely on hardcoded 32bit struct flock
size.

However I double-tested it with systemtap and filed the bug anyway,
https://sourceware.org/bugzilla/show_bug.cgi?id=20251

Thanks for pointing out the glibc example.

> 
> [1] manual/examples/ofdlocks.c
>     https://sourceware.org/git/?p=glibc.git;a=blob;f=manual/examples/ofdlocks.c;h=ba4f0ef4d237e95b8f1e0f37b9c1befd4afda0d4;hb=HEAD
> 


  reply	other threads:[~2016-06-13 17:58 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-10 12:43 [LTP] [PATCH] syscalls/fcntl34: use struct flock64 on 32bit Jiri Jaburek
2016-06-10 14:04 ` Jiri Jaburek
2016-06-10 14:50   ` [LTP] [PATCH v2] syscalls/fcntl34: disable on 32bit without _FILE_OFFSET_BITS==64 Jiri Jaburek
2016-06-13 14:22 ` [LTP] [PATCH] syscalls/fcntl34: use struct flock64 on 32bit Cyril Hrubis
2016-06-13 17:58   ` Jiri Jaburek [this message]
2016-06-13 18:25     ` Cyril Hrubis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=575EF441.5020506@redhat.com \
    --to=jjaburek@redhat.com \
    --cc=ltp@lists.linux.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.