[vte] [ring] Remove newly-added asserts



commit f0f873a6f0944dcae012d1c4b12fe7a582afd474
Author: Behdad Esfahbod <behdad behdad org>
Date:   Tue Aug 25 18:49:23 2009 -0400

    [ring] Remove newly-added asserts
    
    Ok, the ring should be functionally working again now.

 src/ring.c |   11 ++++-------
 1 files changed, 4 insertions(+), 7 deletions(-)
---
diff --git a/src/ring.c b/src/ring.c
index 8d99187..4c39bd8 100644
--- a/src/ring.c
+++ b/src/ring.c
@@ -29,8 +29,10 @@
 static VteRowData *
 _vte_row_data_init (VteRowData *row)
 {
-	g_assert (row->cells == NULL);
-	row->cells = g_array_new(FALSE, TRUE, sizeof(struct vte_charcell));
+	if (row->cells)
+		g_array_set_size (row->cells, 0);
+	else
+		row->cells = g_array_new(FALSE, TRUE, sizeof(struct vte_charcell));
 	row->soft_wrapped = 0;
 	return row;
 }
@@ -56,11 +58,6 @@ _vte_ring_validate(VteRing * ring)
 		g_assert(_vte_ring_contains(ring, i));
 		g_assert(_vte_ring_index(ring, i)->cells != NULL);
 	}
-	max = ring->delta + ring->max;
-	for (; i < max; i++) {
-		g_assert(!_vte_ring_contains(ring, i));
-		g_assert(_vte_ring_index(ring, i)->cells == NULL);
-	}
 }
 #else
 #define _vte_ring_validate(ring) G_STMT_START {} G_STMT_END



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