>From dd97d21b67c6b2c1858096c5a04fbb2d9aafd353 Mon Sep 17 00:00:00 2001
From: Nikolay Sivov <nsivov@codeweavers.com>
Date: Mon, 23 Jan 2012 10:31:55 +0300
Subject: [PATCH 5/5] Try IStream if IPersistStream save failed.

Actually choosing right interface for input needs to be fixed,
the correct query sequence could be imporant for some applications.
This sequence also differs for different reader class versions.
---
 dlls/msxml3/saxreader.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/dlls/msxml3/saxreader.c b/dlls/msxml3/saxreader.c
index 16b85ed..fb41c10 100644
--- a/dlls/msxml3/saxreader.c
+++ b/dlls/msxml3/saxreader.c
@@ -2377,9 +2377,10 @@ static HRESULT internal_parse(
                 if(hr != S_OK)
                 {
                     IStream_Release(stream);
-                    break;
+                    stream = NULL;
                 }
             }
+
             if(stream || IUnknown_QueryInterface(V_UNKNOWN(&varInput),
                         &IID_IStream, (void**)&stream) == S_OK)
             {
-- 
1.5.6.5

