[MPlayer-dev-eng] [PATCH] reset_agids() does not compile on FreeBSD
Bjoern Fischer
bfischer at Techfak.Uni-Bielefeld.DE
Sun Jan 20 21:16:29 CET 2002
On Sun, Jan 20, 2002 at 08:43:24PM +0100, Felix Buenemann wrote:
> > reset_agids() in libmpdemux/dvdauth.c uses the linux-type dvd
> > ioctl API and does not compile on FreeBSD. I did not found
> > any references to reset_agids() in the whole code, so I simply
> > made it a NOP.
> >
> I don't see no patch =)
>
> > Please tell me, if reset_agids() is needed in future, then I
> > would post a FreeBSD version of reset_agids().
> If you can do it, why not!?
Oops, new mutt version and ENOCOF (out-of-coffee-error).
Ok, since reset_agids() is used in tonight's CVS, here is the real
patch:
-------------- next part --------------
--- dvdauth.c 2002/01/20 19:32:42 1.1
+++ dvdauth.c 2002/01/20 19:44:35
@@ -159,6 +159,16 @@
static void reset_agids ( DVDHandle dvd )
{
+#if !defined(DVD_AUTH) && defined(DVDIOCREPORTKEY)
+ struct dvd_authinfo ai;
+ int i;
+ for (i = 0; i < 4; i++) {
+ memset(&ai, 0, sizeof(ai));
+ ai.format = DVD_INVALIDATE_AGID;
+ ai.agid = i;
+ ioctl(dvd, DVDIOCREPORTKEY, &ai);
+ }
+#else
dvd_authinfo ai;
int i;
for (i = 0; i < 4; i++) {
@@ -167,6 +177,7 @@
ai.lsa.agid = i;
DVDAuth(dvd, &ai);
}
+#endif
}
More information about the MPlayer-dev-eng
mailing list