title: corrupted double-linked list?
body: <p>I am just debugging a big project and and getting this error </p>
  
  <pre><code>*** glibc detected *** p_appmanager/obj/appmanager: corrupted double-linked list: 0x08325e18 **
  </code></pre>
  
  <p>I have tried to debug the code with the valgrind, but I am not much familiar with this tool. So I am dumping the logs here if you can find out anything from them please let me know.</p>
  
  <p>Can anyone explain what the following error message could mean? </p>
  
  <pre><code>==2181== Invalid read of size 1
  ==2181==    at 0x402C658: strlen (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x40FCC2D: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::operator&lt;&lt; &lt;std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x4359234 is 12 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 1
  ==2181==    at 0x402C663: strlen (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x40FCC2D: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::operator&lt;&lt; &lt;std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x4359235 is 13 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 4
  ==2181==    at 0x402DA08: memcpy (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4106850: std::basic_streambuf&lt;char, std::char_traits&lt;char&gt; &gt;::xsputn(char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40D8CDF: std::basic_filebuf&lt;char, std::char_traits&lt;char&gt; &gt;::xsputn(char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40FC9AA: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::__ostream_insert&lt;char, std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40FCC3D: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::operator&lt;&lt; &lt;std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x4359234 is 12 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 2
  ==2181==    at 0x402DA60: memcpy (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4106850: std::basic_streambuf&lt;char, std::char_traits&lt;char&gt; &gt;::xsputn(char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40D8CDF: std::basic_filebuf&lt;char, std::char_traits&lt;char&gt; &gt;::xsputn(char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40FC9AA: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::__ostream_insert&lt;char, std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40FCC3D: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::operator&lt;&lt; &lt;std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x4359238 is 16 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 1
  ==2181==    at 0x402DA90: memcpy (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4106850: std::basic_streambuf&lt;char, std::char_traits&lt;char&gt; &gt;::xsputn(char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40D8CDF: std::basic_filebuf&lt;char, std::char_traits&lt;char&gt; &gt;::xsputn(char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40FC9AA: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::__ostream_insert&lt;char, std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40FCC3D: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::operator&lt;&lt; &lt;std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x435923a is 18 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 1
  ==2181==    at 0x402DA9C: memcpy (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4106850: std::basic_streambuf&lt;char, std::char_traits&lt;char&gt; &gt;::xsputn(char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40D8CDF: std::basic_filebuf&lt;char, std::char_traits&lt;char&gt; &gt;::xsputn(char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40FC9AA: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::__ostream_insert&lt;char, std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*, int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x40FCC3D: std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp; std::operator&lt;&lt; &lt;std::char_traits&lt;char&gt; &gt;(std::basic_ostream&lt;char, std::char_traits&lt;char&gt; &gt;&amp;, char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x43f0936 is 14 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  stop tablet
  ==2181== Invalid read of size 1
  ==2181==    at 0x402C658: strlen (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4108EF1: std::string::operator=(char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x45b2e14 is 12 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 1
  ==2181==    at 0x402C663: strlen (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4108EF1: std::string::operator=(char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x45b2e15 is 13 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 1
  ==2181==    at 0x402DAEA: memcpy (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4108C7A: std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4108CF8: std::string::assign(char const*, unsigned int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4108F05: std::string::operator=(char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x45b2e19 is 17 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 4
  ==2181==    at 0x402DB18: memcpy (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4108C7A: std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4108CF8: std::string::assign(char const*, unsigned int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4108F05: std::string::operator=(char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x45b2e14 is 12 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  Success:: tablet process terminated Successfully.
  CONSOLE&gt;start tablet
  Success:: tablet Process Created Successfully
  CONSOLE&gt;stop tablet
  ==2181== Invalid read of size 4
  ==2181==    at 0x402DA08: memcpy (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4108C7A: std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4108CF8: std::string::assign(char const*, unsigned int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4108F05: std::string::operator=(char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x45dd8c4 is 12 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  ==2181== Invalid read of size 2
  ==2181==    at 0x402DA60: memcpy (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x4108C7A: std::string::_M_replace_safe(unsigned int, unsigned int, char const*, unsigned int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4108CF8: std::string::assign(char const*, unsigned int) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4108F05: std::string::operator=(char const*) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181==  Address 0x45dd8c8 is 16 bytes inside a block of size 21 free'd
  ==2181==    at 0x402ACFC: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
  ==2181==    by 0x410899A: std::string::_Rep::_M_destroy(std::allocator&lt;char&gt; const&amp;) (in /usr/lib/i386-linux-gnu/libstdc++.so.6.0.16)
  ==2181==    by 0x4071B37: void std::_Destroy_aux&lt;false&gt;::__destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x40717DC: void std::_Destroy&lt;std::string*&gt;(std::string*, std::string*) (in /usr/lib/libparser.so)
  ==2181==    by 0x4071041: void std::_Destroy&lt;std::string*, std::string&gt;(std::string*, std::string*, std::allocator&lt;std::string&gt;&amp;) (in /usr/lib/libparser.so)
  ==2181==    by 0x407088A: std::vector&lt;std::string, std::allocator&lt;std::string&gt; &gt;::~vector() (in /usr/lib/libparser.so)
  ==2181==    by 0x406F497: Parser::parse(std::string) (in /usr/lib/libparser.so)
  ==2181==    by 0x40729E2: getMessage(int, Message**) (in /usr/lib/libparser.so)
  ==2181==    by 0x804CB99: fifoThread(void*) (in /home/cleanhands/SBISSW (2)/p_appmanager/obj/appmanager)
  ==2181==    by 0x4054D4B: start_thread (pthread_create.c:308)
  ==2181==    by 0x4269DDD: clone (clone.S:130)
  ==2181== 
  </code></pre>