[brasero/gnome-2-28] Fix #601871 - Wrong remaining space when audio CD of size greater than 70 min



commit 084b008aada686d2c86563f0c49595348820d619
Author: Philippe Rouquier <bonfire-app wanadoo fr>
Date:   Sat Nov 14 13:03:37 2009 +0100

    Fix #601871 -  Wrong remaining space when audio CD of size greater than 70 min
    We used the bytes instead of the blocks which explains the discrepancy

 libbrasero-burn/brasero-dest-selection.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/libbrasero-burn/brasero-dest-selection.c b/libbrasero-burn/brasero-dest-selection.c
index a4c6fcf..1c3d21f 100644
--- a/libbrasero-burn/brasero-dest-selection.c
+++ b/libbrasero-burn/brasero-dest-selection.c
@@ -59,6 +59,8 @@
 #include "brasero-session.h"
 #include "brasero-session-cfg.h"
 
+#define BRASERO_SECTORS_TO_DURATION(sectors)	(guint64) ((sectors) * 1000000000LL / 75LL)
+
 typedef struct _BraseroDestSelectionPrivate BraseroDestSelectionPrivate;
 struct _BraseroDestSelectionPrivate
 {
@@ -700,7 +702,7 @@ brasero_dest_selection_format_medium_string (BraseroMediumSelection *selection,
 	else if (brasero_track_type_get_has_stream (input)
 	|| (brasero_track_type_get_has_medium (input)
 	&& (brasero_track_type_get_medium_type (input) & BRASERO_MEDIUM_HAS_AUDIO)))
-		size_string = brasero_units_get_time_string (BRASERO_BYTES_TO_DURATION (size_bytes - session_bytes),
+		size_string = brasero_units_get_time_string (BRASERO_SECTORS_TO_DURATION (blocks),
 							     TRUE,
 							     TRUE);
 	else



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]