gstreamer1.0-dreamsinks: update to 1.1r2
[opendreambox.git] / meta-opendreambox / recipes-multimedia / dvd+rw-tools / files / 01-growisofs-pioneer.dpatch
1 #!/bin/sh /usr/share/dpatch/dpatch-run
2 ## 01-growisofs-pioneer.dpatch
3 ##
4 ## DP: Fixes to fail closing session on some PIONEER DVD-RW drives
5
6 @DPATCH@
7
8 diff -Naurp dvd+rw-tools-7.1.orig/growisofs_mmc.cpp dvd+rw-tools-7.1/growisofs_mmc.cpp
9 --- dvd+rw-tools-7.1.orig/growisofs_mmc.cpp     2008-03-04 17:47:49.000000000 +0000
10 +++ dvd+rw-tools-7.1/growisofs_mmc.cpp  2008-04-01 09:01:20.000000000 +0000
11 @@ -1743,8 +1743,17 @@ void plus_rw_finalize ()
12         cmd[1] = 0x01;          // "IMMED"
13         cmd[2] = 0x02;          // "Close session"
14         cmd[9] = 0;
15 -       if ((err=cmd.transport()))
16 -           sperror ("CLOSE SESSION",err);
17 +       
18 +       // it seems, that pioneer is a bit crappy
19 +       while (err=cmd.transport()) {
20 +           if (SK(err)==0x2 && ASC(err)==0x04 && ASCQ(err)==0x07) {
21 +                   sperror ("CLOSE SESSION (but try to continue)",err);
22 +                   usleep(10000);
23 +           } else {
24 +                   sperror ("CLOSE SESSION",err);
25 +                   break;
26 +           }
27 +       }
28  
29         if (wait_for_unit (cmd)) break;
30