From fd06bca1513e0137cce50bb15e09bf1b5ea474a7 Mon Sep 17 00:00:00 2001 From: Eric House Date: Mon, 6 Jul 2015 20:24:45 -0700 Subject: [PATCH] assert stream version being set consistently, not changed --- xwords4/common/memstream.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/xwords4/common/memstream.c b/xwords4/common/memstream.c index 129542f89..fcf62c47b 100644 --- a/xwords4/common/memstream.c +++ b/xwords4/common/memstream.c @@ -396,6 +396,8 @@ static void mem_stream_setVersion( XWStreamCtxt* p_sctx, XP_U16 vers ) { MemStreamCtxt* stream = (MemStreamCtxt*)p_sctx; + /* Something's wrong if we're changing it -- I think */ + XP_ASSERT( 0 == stream->version || vers == stream->version ); stream->version = vers; } /* mem_stream_setVersion */