public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
From: Clemens Ladisch <clemens@ladisch.de>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Mauro Carvalho Chehab <mchehab@infradead.org>,
	linux-media@vger.kernel.org, alsa-devel@alsa-project.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] media: fix truncated entity specification
Date: Tue, 15 Nov 2011 14:02:21 +0100	[thread overview]
Message-ID: <4EC262DD.1070502@ladisch.de> (raw)
In-Reply-To: <201111150148.07957.laurent.pinchart@ideasonboard.com>

Laurent Pinchart wrote:
> On Saturday 05 November 2011 22:42:01 Clemens Ladisch wrote:
> > When enumerating an entity, assign the entire entity specification
> > instead of only the first two words.  (This requires giving the
> > specification union a name.)
> 
> What about this (untested) simpler patch ?
> 
> -	u_ent.v4l.major = ent->v4l.major;
> -	u_ent.v4l.minor = ent->v4l.minor;
> +	memcpy(&u_ent.raw, &ent->raw, sizeof(u_ent.raw));

I would have written it this way if ent->raw actually existed.
(And please don't tell me you want to increase the size of
struct media_entity by 172 bytes.  :)


Regards,
Clemens

  reply	other threads:[~2011-11-15 13:10 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-05 21:42 [PATCH] media: fix truncated entity specification Clemens Ladisch
2011-11-15  0:47 ` Laurent Pinchart
2011-11-15 13:02   ` Clemens Ladisch [this message]
2011-11-16  0:33     ` Laurent Pinchart
2011-11-16  7:42       ` Clemens Ladisch

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=4EC262DD.1070502@ladisch.de \
    --to=clemens@ladisch.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@infradead.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox