MantisBT - ParaView
View Issue Details
0002926ParaView(No Category)public2006-03-01 19:312009-12-09 14:49
Andrew Maclean 
Berk Geveci 
urgentmajoralways
closedfixed 
 
 
0002926: Startup fails with: "vector iterator not dereferencable"
Compiler: Visual Studio 8.0

After building with Visual Studio 8.0, startup fails with: "vector iterator not dereferencable"

The problem seems to be in vtkClientServerStream.cxx line 240:
  memcpy(&*this->Internal->Data.end() - length, data, length);

Called from: vtkProcessModule.cxx line 793.


A possible solution is to change vtkClientServerStream.cxx line 240 to:
vtkClientServerStream.cxx line 240:
  memcpy(&this->Internal->Data.end() - length, data, length);


But you should check if this->Internal->Data is empty first.
No tags attached.
Issue History
2009-12-09 14:49Berk GeveciProject@3@ => ParaView
2011-06-16 13:09Zack GalbreathCategory => (No Category)

Notes
(0003821)
Andrew Maclean   
2006-03-01 20:09   
As I suspected the solution is not as simple as outlined below, just doing memcpy(&this->Internal->Data.end() - length, data, length);
causes other errors.
(0003822)
Andrew Maclean   
2006-03-01 20:23   
But this works:
  memcpy(&*(--this->Internal->Data.end()) - length + 1, data, length);

However we run into the same problems at int vtkClientServerStream::ParseData() in line 1205.
This section of code will definitely need a rewrite.
(0007779)
Berk Geveci   
2007-06-02 09:39   
Is this true for 3.0?
(0007925)
Andrew Maclean   
2007-06-24 20:08   
Everything compiles Ok with Paraview 3. I finally got around to installing QT 4.2.3

So I think you can close this bug.

Andrew