Differences between release and debug binaries??


A

AntonioSACE

We have been using two web services from a asp.net app for two years, then
the solution was ported to VS 2008 and the web services now throw the
following exception:
Error Message:There is an error in XML document (1, 344).
Stack Trace: at
System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader,
String encodingStyle, XmlDeserializationEvents events)
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader
xmlReader, String encodingStyle)
The weird thing is, if I compile the project with debug enabled, instead of
release, everything works fine!
For now we have the web app working in debug mode, but obviously we need to
pass soon in release mode because of speed concerns.
Any ideas??
Thanks
 
Ad

Advertisements

G

George Ter-Saakov

I would examine the actual XML document
error actually indicates the you have some problem on line 1, character 344
I guess you do not have "\r\n" (C#) in your XML documents
Just capture XML document and open it with Visual Studio... run cursor and
watch status bar.. It shows the position..


George.
 
A

AntonioSACE

Hi George,
thank you for your reply but I think I explained in a bad way the problem.
In fact we recognize that there is an error in the xml. It is truncated at
the end. The strange thing is that if we compile the application in release
mode we have this problem, but if we compile the application in debug mode
the application works fine and we receive the whole XML. So we are wondering
that, based on the compilation mode, the application change behaviour!! Any
ideas on that?
 
G

George Ter-Saakov

I see now....There are some differences between Debug and Release
versions...
So it's possible that you have a bug in your application which does not
appear in debug....
What is your environment, C#? Cause the differences much greater if you use
Managed/Unmanaged C++

Here are some things for you to look at..

1. Timing... Timing might be different in release mode... So if for example
you rely that something will be done in 10 seconds, in release mode it might
be done much quicker...

2. Multithreading access... If you are sharing variables between threads
then you might be able to get away and have no problem accessing them in
debug mode without properly serializing access to them. But in release mode
it might show up...


Also you said you are using VS 2008... Can you switch to VS 2005? VS 2008 is
still new and may be it's just a simple bug in compiler?


George.
 
A

AntonioSACE

Hi George,
unfortunately we alredy made the check you sent and, as you said, we think
that the problem is a bug in VS2008. We'll ask Microsoft to check. Thank you
very much for your time.
 
Ad

Advertisements

J

Jef.ptc

Hi,

I am currently facing exactly the same issue with Visual Studio 2005.
Did you find a way to solve this problem ?
 
Ad

Advertisements


Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top