Valgrind
#1
I was just wondering, are there any Linux gurus here who could put MCServer through Valgrind? Could help solve some mysterious memory issues; unfortunately I lack the expertise to do this.
Reply
Thanks given by:
#2
I will google it tonight and try if i can do it.
As it keeps crashing on my linux vps. and its annoying :p.
Reply
Thanks given by:
#3
I've used Valgrind before, and you don't need to be a guru to use itTongue
Reply
Thanks given by:
#4
I just checked out: http://www.cprogramming.com/debugging/valgrind.html

I asume this gives enough info for me to run it.
Btw what kind of check(s) do you want me to try out ?

Btw isnt the debug in the makefile missing -g ?

I was using client 1.3.2
Server rev 1007

First:
Code:
==1357== Thread 7:
==1357== Conditional jump or move depends on uninitialised value(s)
==1357==    at 0x69BC3E: cChunkSender::Execute() (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D19B8: cIsThread::thrExecute(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==

Second:
Code:
==1357== Thread 14:
==1357== Conditional jump or move depends on uninitialised value(s)
==1357==    at 0x68D232: cSimulatorManager::Simulate(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6303E7: cWorld::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5B476E: cRoot::TickWorlds(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6501EF: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
==1357== Conditional jump or move depends on uninitialised value(s)
==1357==    at 0x62E0AC: cWorld::TickWeather(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6303F5: cWorld::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5B476E: cRoot::TickWorlds(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6501EF: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==

Third:
Code:
[22:05:09] Client "83.84.152.69" connected!
==1357== Mismatched free() / delete / delete []
==1357==    at 0x4C25374: operator delete(void*) (vg_replace_malloc.c:480)
==1357==    by 0x64F0CF: cProtocolRecognizer::~cProtocolRecognizer() (in /root/MCServer-Run/MCServer)
==1357==    by 0x5BEBEE: cClientHandle::~cClientHandle() (in /root/MCServer-Run/MCServer)
==1357==    by 0x650296: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==  Address 0x68f4110 is 0 bytes inside a block of size 513 alloc'd
==1357==    at 0x4C264F0: operator new[](unsigned long) (vg_replace_malloc.c:363)
==1357==    by 0x5C5E0B: cByteBuffer::cByteBuffer(int) (in /root/MCServer-Run/MCServer)
==1357==    by 0x64F264: cProtocolRecognizer::cProtocolRecognizer(cClientHandle*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5BBE28: cClientHandle::cClientHandle(cSocket const*, int) (in /root/MCServer-Run/MCServer)
==1357==    by 0x64FBD4: cServer::StartListenClient() (in /root/MCServer-Run/MCServer)
==1357==    by 0x64FCF7: cServer::ServerListenThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
==1357== Mismatched free() / delete / delete []
==1357==    at 0x4C25374: operator delete(void*) (vg_replace_malloc.c:480)
==1357==    by 0x5BEC23: cClientHandle::~cClientHandle() (in /root/MCServer-Run/MCServer)
==1357==    by 0x650296: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==  Address 0x60ba980 is 0 bytes inside a block of size 65,537 alloc'd
==1357==    at 0x4C264F0: operator new[](unsigned long) (vg_replace_malloc.c:363)
==1357==    by 0x5C5E0B: cByteBuffer::cByteBuffer(int) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5BBD5D: cClientHandle::cClientHandle(cSocket const*, int) (in /root/MCServer-Run/MCServer)
==1357==    by 0x64FBD4: cServer::StartListenClient() (in /root/MCServer-Run/MCServer)
==1357==    by 0x64FCF7: cServer::ServerListenThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==

Fourth:
Code:
[22:05:56] Player ThuGhacK has permissions:
[22:05:56] *
==1357== Conditional jump or move depends on uninitialised value(s)
==1357==    at 0x5AC86F: cBlockDirtHandler::OnUpdate(cWorld*, int, int, int) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6906BC: cChunk::TickBlocks(MTRand&) (in /root/MCServer-Run/MCServer)
==1357==    by 0x690E0C: cChunk::Tick(float, MTRand&) (in /root/MCServer-Run/MCServer)
==1357==    by 0x65E2CB: cChunkMap::Tick(float, MTRand&) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6303C7: cWorld::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5B476E: cRoot::TickWorlds(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6501EF: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServer)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==

Another?
Code:
==1357== Mismatched free() / delete / delete []
==1357==    at 0x4C25374: operator delete(void*) (vg_replace_malloc.c:480)
==1357==    by 0x647FD9: cProtocol125::~cProtocol125() (in /root/MCServer-Run/MC       Server)
==1357==    by 0x645845: cProtocol132::~cProtocol132() (in /root/MCServer-Run/MC       Server)
==1357==    by 0x64F0C6: cProtocolRecognizer::~cProtocolRecognizer() (in /root/M       CServer-Run/MCServer)
==1357==    by 0x5BEBEE: cClientHandle::~cClientHandle() (in /root/MCServer-Run/       MCServer)
==1357==    by 0x650296: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer       )
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==  Address 0x6007260 is 0 bytes inside a block of size 65,537 alloc'd
==1357==    at 0x4C264F0: operator new[](unsigned long) (vg_replace_malloc.c:363       )
==1357==    by 0x5C5E0B: cByteBuffer::cByteBuffer(int) (in /root/MCServer-Run/MC       Server)
==1357==    by 0x649FDC: cProtocol125::cProtocol125(cClientHandle*) (in /root/MC       Server-Run/MCServer)
==1357==    by 0x6452BC: cProtocol132::cProtocol132(cClientHandle*) (in /root/MC       Server-Run/MCServer)
==1357==    by 0x64F570: cProtocolRecognizer::TryRecognizeProtocol() (in /root/M       CServer-Run/MCServer)
==1357==    by 0x64F617: cProtocolRecognizer::DataReceived(char const*, int) (in        /root/MCServer-Run/MCServer)
==1357==    by 0x5BB58D: cClientHandle::DataReceived(char const*, int) (in /root       /MCServer-Run/MCServer)
==1357==    by 0x5D2850: cSocketThreads::cSocketThread::ReadFromSockets(fd_set*)        (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D350D: cSocketThreads::cSocketThread::Execute() (in /root/MCSe       rver-Run/MCServer)
==1357==    by 0x5D19B8: cIsThread::thrExecute(void*) (in /root/MCServer-Run/MCS       erver)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
[22:09:50] Deleting cPlayer "ThuGhacK" at 0x7f48f60, ID 1; inv win 0xf4c57b0
[22:09:50] Player 0x7f48f60 deleted

This is just 1 log from boot up to me requesting server list.
to me actually logging in and disconnecting.

Just in case whole log from the console without the first error as console limits
Code:
[22:03:37] Binding /top (core.top)
[22:03:37] Binding /gm (core.changegm)
[22:03:37] Binding /gotoworld (core.gotoworld)
[22:03:37] Binding /coords (core.coords)
[22:03:37] Binding /viewdistance (core.viewdistance)
[22:03:37] Binding /regeneratechunk (core.regeneratechunk)
[22:03:37] Initialized Core v.8
[22:03:37] cWebPlugin::cWebPlugin()
[22:03:37] Binding /coins (eco.coins)
[22:03:37] Initialized tEconomy v.1
[22:03:37] cWebPlugin::cWebPlugin()
[22:03:38] Binding /tools (tools.tools)
[22:03:38] Initialized tTools v.1
[22:03:38] cWebPlugin::cWebPlugin()
[22:03:38] Initialized ChatLog v.2
[22:03:38] cWebPlugin::cWebPlugin()
[22:03:38] Binding /sethome (core.home)
[22:03:38] Binding /home (core.home)
[22:03:38] Initialized tHome v.1
[22:03:38] cWebPlugin::cWebPlugin()
[22:03:38] Binding /heal (extra.heal)
[22:03:38] Binding /feed (extra.feed)
[22:03:38] Initialized tExtra v.1
[22:03:38] cWebPlugin::cWebPlugin()
[22:03:38] Binding /weather (Rainy.weather)
[22:03:38] Initialized Rainy v2
[22:03:38] Loaded 11 plugin(s)
[22:03:38] Loading MonsterConfig...
[22:03:38] Starting Authenticator...
[22:03:38] Starting worlds...
[22:03:38] Preparing spawn area in world "Kami"...
[22:03:38] 399 chunks to load, 0 chunks to generate
[22:03:44] 87 chunks to load, 0 chunks to generate
[22:03:45] Lighting spawn area in world "Kami"...
[22:03:45] 0 chunks remaining to light
[22:03:45] Preparing spawn area in world "Maou"...
[22:03:45] 399 chunks to load, 0 chunks to generate
[22:03:50] 99 chunks to load, 0 chunks to generate
[22:03:51] Lighting spawn area in world "Maou"...
[22:03:51] 0 chunks remaining to light
[22:03:51] Starting server...
[22:03:51] ServerListenThread
[22:03:51] ServerTickThread
==1357== Thread 14:
==1357== Conditional jump or move depends on uninitialised value(s)
==1357==    at 0x68D232: cSimulatorManager::Simulate(float) (in /root/MCServer-R       un/MCServer)
==1357==    by 0x6303E7: cWorld::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5B476E: cRoot::TickWorlds(float) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x6501EF: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer       )
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
==1357== Conditional jump or move depends on uninitialised value(s)
==1357==    at 0x62E0AC: cWorld::TickWeather(float) (in /root/MCServer-Run/MCSer       ver)
==1357==    by 0x6303F5: cWorld::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5B476E: cRoot::TickWorlds(float) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x6501EF: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer       )
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
[22:03:51] Starting rainstorm!
[22:03:51] Starting InputThread...
[22:03:51] Initialization done, server running now.
[22:05:09] Client "83.84.152.69" connected!
==1357== Mismatched free() / delete / delete []
==1357==    at 0x4C25374: operator delete(void*) (vg_replace_malloc.c:480)
==1357==    by 0x64F0CF: cProtocolRecognizer::~cProtocolRecognizer() (in /root/M       CServer-Run/MCServer)
==1357==    by 0x5BEBEE: cClientHandle::~cClientHandle() (in /root/MCServer-Run/       MCServer)
==1357==    by 0x650296: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer       )
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==  Address 0x68f4110 is 0 bytes inside a block of size 513 alloc'd
==1357==    at 0x4C264F0: operator new[](unsigned long) (vg_replace_malloc.c:363       )
==1357==    by 0x5C5E0B: cByteBuffer::cByteBuffer(int) (in /root/MCServer-Run/MC       Server)
==1357==    by 0x64F264: cProtocolRecognizer::cProtocolRecognizer(cClientHandle*       ) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5BBE28: cClientHandle::cClientHandle(cSocket const*, int) (in /       root/MCServer-Run/MCServer)
==1357==    by 0x64FBD4: cServer::StartListenClient() (in /root/MCServer-Run/MCS       erver)
==1357==    by 0x64FCF7: cServer::ServerListenThread(void*) (in /root/MCServer-R       un/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
==1357== Mismatched free() / delete / delete []
==1357==    at 0x4C25374: operator delete(void*) (vg_replace_malloc.c:480)
==1357==    by 0x5BEC23: cClientHandle::~cClientHandle() (in /root/MCServer-Run/       MCServer)
==1357==    by 0x650296: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer       )
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==  Address 0x60ba980 is 0 bytes inside a block of size 65,537 alloc'd
==1357==    at 0x4C264F0: operator new[](unsigned long) (vg_replace_malloc.c:363       )
==1357==    by 0x5C5E0B: cByteBuffer::cByteBuffer(int) (in /root/MCServer-Run/MC       Server)
==1357==    by 0x5BBD5D: cClientHandle::cClientHandle(cSocket const*, int) (in /       root/MCServer-Run/MCServer)
==1357==    by 0x64FBD4: cServer::StartListenClient() (in /root/MCServer-Run/MCS       erver)
==1357==    by 0x64FCF7: cServer::ServerListenThread(void*) (in /root/MCServer-R       un/MCServer)
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
[22:05:54] Client "83.84.152.69" connected!
[22:05:55] Got 200 OK :D
[22:05:55] Got result: YES
[22:05:55] Result was "YES", so player is authenticated!
[22:05:56] Player ThuGhacK has permissions:
[22:05:56] *
==1357== Conditional jump or move depends on uninitialised value(s)
==1357==    at 0x5AC86F: cBlockDirtHandler::OnUpdate(cWorld*, int, int, int) (in        /root/MCServer-Run/MCServer)
==1357==    by 0x6906BC: cChunk::TickBlocks(MTRand&) (in /root/MCServer-Run/MCSe       rver)
==1357==    by 0x690E0C: cChunk::Tick(float, MTRand&) (in /root/MCServer-Run/MCS       erver)
==1357==    by 0x65E2CB: cChunkMap::Tick(float, MTRand&) (in /root/MCServer-Run/       MCServer)
==1357==    by 0x6303C7: cWorld::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x5B476E: cRoot::TickWorlds(float) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x6501EF: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer       )
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
[22:06:48] Saving all chunks...
[22:06:48] Saving all chunks...
[22:06:49] Saved all chunks in world Kami
[22:06:49] Saved all chunks in world Maou
[22:07:13] [ThuGhacK]: err
[22:09:37] ThuGhacK returned to spawn.
==1357== Mismatched free() / delete / delete []
==1357==    at 0x4C25374: operator delete(void*) (vg_replace_malloc.c:480)
==1357==    by 0x647FD9: cProtocol125::~cProtocol125() (in /root/MCServer-Run/MC       Server)
==1357==    by 0x645845: cProtocol132::~cProtocol132() (in /root/MCServer-Run/MC       Server)
==1357==    by 0x64F0C6: cProtocolRecognizer::~cProtocolRecognizer() (in /root/M       CServer-Run/MCServer)
==1357==    by 0x5BEBEE: cClientHandle::~cClientHandle() (in /root/MCServer-Run/       MCServer)
==1357==    by 0x650296: cServer::Tick(float) (in /root/MCServer-Run/MCServer)
==1357==    by 0x6503A2: ServerTickThread(void*) (in /root/MCServer-Run/MCServer       )
==1357==    by 0x5D0C9B: cThread::MyThread(void*) (in /root/MCServer-Run/MCServe       r)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==  Address 0x6007260 is 0 bytes inside a block of size 65,537 alloc'd
==1357==    at 0x4C264F0: operator new[](unsigned long) (vg_replace_malloc.c:363       )
==1357==    by 0x5C5E0B: cByteBuffer::cByteBuffer(int) (in /root/MCServer-Run/MC       Server)
==1357==    by 0x649FDC: cProtocol125::cProtocol125(cClientHandle*) (in /root/MC       Server-Run/MCServer)
==1357==    by 0x6452BC: cProtocol132::cProtocol132(cClientHandle*) (in /root/MC       Server-Run/MCServer)
==1357==    by 0x64F570: cProtocolRecognizer::TryRecognizeProtocol() (in /root/M       CServer-Run/MCServer)
==1357==    by 0x64F617: cProtocolRecognizer::DataReceived(char const*, int) (in        /root/MCServer-Run/MCServer)
==1357==    by 0x5BB58D: cClientHandle::DataReceived(char const*, int) (in /root       /MCServer-Run/MCServer)
==1357==    by 0x5D2850: cSocketThreads::cSocketThread::ReadFromSockets(fd_set*)        (in /root/MCServer-Run/MCServer)
==1357==    by 0x5D350D: cSocketThreads::cSocketThread::Execute() (in /root/MCSe       rver-Run/MCServer)
==1357==    by 0x5D19B8: cIsThread::thrExecute(void*) (in /root/MCServer-Run/MCS       erver)
==1357==    by 0x55DF8C9: start_thread (pthread_create.c:300)
==1357==    by 0x58C4B6C: clone (clone.S:112)
==1357==
[22:09:50] Deleting cPlayer "ThuGhacK" at 0x7f48f60, ID 1; inv win 0xf4c57b0
[22:09:50] Player 0x7f48f60 deleted
[22:10:19] Saving all chunks...
[22:10:19] Saving all chunks...
[22:10:19] Saved all chunks in world Kami
[22:10:22] Saved all chunks in world Maou
[22:12:52] Saving all chunks...
[22:12:52] Saved all chunks in world Maou
[22:12:52] Saving all chunks...
[22:12:52] Saved all chunks in world Kami
[22:12:59] Client "204.236.247.158" connected!
[22:13:39] Client "83.84.152.69" connected!
[22:15:21] Saving all chunks...
[22:15:21] Saved all chunks in world Maou
[22:15:22] Saving all chunks...
[22:15:22] Saved all chunks in world Kami
Reply
Thanks given by:
#5
Sorry for the late answer, and thanks for diving into this issue Smile

I've only skimmed through that article, from what i can tell, we desperately need the invalid pointer use test. So if you have to choose among options, choose that one. Try running the server for some time, log into it and move around a bit, just do stuff Smile

Try to redirect the output to a file, so that you're not limited by the console size:
Code:
CommandToExecute --args > output.log 2> error.log

The makefile might be missing whatever params are necessary, not many people use it and no-one takes care of it actively. But the -g option is there, in the pedantic and debug build sections, it actually says "-ggdb", which should stand for "generate debugging info, gdb-style".

I'll crunch through those logs you've posted so far, seems like an interesting find.
I think I've fixed all but the fourth one (rev 1010). For the life of me I cannot figure out what can be uninitialized there.
Reply
Thanks given by:
#6
I will run a invalid pointer test in a bit.
Just came home. and thanks for clearing up the -g flag.

I will do a svn update and run the test + the output to log file and run around a bit.
I could even get a second person on if needed probably if str_Warrior is online at that time else that would be another time :p.

Edit:
If you read.
http://www.cprogramming.com/debugging/valgrind.html
Finding Invalid Pointer Use With Valgrind

If i'm correct it should already be listed @ the memcheck stuff i posted.
If you could read tru that and just tell me what command you want me to run.

It might make it a bit more clear for both of us as what output is given + what i should be giving.
Reply
Thanks given by:
#7
memcheck will be enough; we have a leak checker on Windows in debug builds by default, so there shouldn't be too many leaks.

However, I suspect there is an invalid pointer use - memory gets overwritten somewhere where it shouldn't. I think it started around the time I started playing with Floody fluid sim, so try setting that as the simulator and using a bucket. I don't think two players are necessary, one should be enough.

I wonder, though, why your listings don't have line numbers in them. Verify that you're running a debug version of MCServer, try cleaning and rebuilding (make clean; make) and if it doesn't help, try changing the compiler flag from -ggdb to -g in the GNUmakefile (also a full rebuild needed).
Reply
Thanks given by:
#8
Sure i always simply do make btw.
But will run a make clean first this time.

And if it doesnt show line numbers it is cause of debug info missing.
So will change it to -g just in case.

So just login run around like always get a bucket with water and trow it around a bit ? :p
Reply
Thanks given by:
#9
yup Smile
Reply
Thanks given by:
#10
OH i just noticed you already fixed some and commited them yay.
Should these also stop some of the crashes i have been having ?

If i remember correctly i even had crashes before floody was added.

Edit:

Forum acting up but ontopic:
Could it be i also have to include a db file like with windows for debugging ?

Edit2:

Running it now with -g seems server is this time slower then before so i guess this time the errors should be more useful Smile.

Edit3:

Its hard to test lol. getting timeout and chunks take for ever to load haha.
Reply
Thanks given by:




Users browsing this thread: 1 Guest(s)