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

[XaraXtreme-commits] Commit Complete



Commit by  : gerry
Repository : xara
Revision   : 1521
Date       : Tue Jul 25 12:03:30 BST 2006

Changed paths:
   M /Trunk/XaraLX/wxOil/camprocess.cpp
   M /Trunk/XaraLX/wxOil/xpoilflt.cpp

Now only processes one buffer full of stdout and only treats correctly formed stderr as errors


Diff:
Index: Trunk/XaraLX/wxOil/xpoilflt.cpp
===================================================================
--- Trunk/XaraLX/wxOil/xpoilflt.cpp	(revision 1520)
+++ Trunk/XaraLX/wxOil/xpoilflt.cpp	(revision 1521)
@@ -1653,8 +1653,8 @@
 				}
 				else
 				{
-//					TRACEUSER("Gerry", _T("XPFError:%s"), line.c_str());
-					m_Errors.Add(line);
+//					TRACEUSER("Gerry", _T("Skipping stderr:%s"), line.c_str());
+//					m_Errors.Add(line);
 				}
 			}
 		}
Index: Trunk/XaraLX/wxOil/camprocess.cpp
===================================================================
--- Trunk/XaraLX/wxOil/camprocess.cpp	(revision 1520)
+++ Trunk/XaraLX/wxOil/camprocess.cpp	(revision 1521)
@@ -171,18 +171,16 @@
 				size_t NumRead = 4096;
 				BYTE Buffer[4096];
 
-				while (NumRead > 0)
-				{
-					// Read a buffer full
-					GetInputStream()->Read(Buffer, 4096);
+				// Read a buffer full
+				GetInputStream()->Read(Buffer, 4096);
 
-					NumRead = GetInputStream()->LastRead();
+				NumRead = GetInputStream()->LastRead();
 
-					// Write the buffer to the file
-					if (NumRead > 0)
-					{
-						m_pOutFile->write(Buffer, NumRead);
-					}
+				// Write the buffer to the file
+				if (NumRead > 0)
+				{
+//					TRACEUSER("Gerry", _T("Writing %d bytes of stdout"), NumRead);
+					m_pOutFile->write(Buffer, NumRead);
 				}
 			}
 		}


Xara