Forum

Results 1 to 11 of 11
  1. #1
    Join Date
    November 2017
    Posts
    13

    Question crash crash brrr

    Code: https://hastebin.com/ivowepiteb.m
    Crash: "The thread tried to read from or write to a virtual adress for which it does not have the appropriate access.
    Using: Visual Studio 2017
    DLL: x64 Release
    Client causes crash: https://prnt.sc/ph49ov
    Client not causing crash & displaying information properly: https://prnt.sc/ph49pl
    API version: 23 (3.3.2)


    I don't get it why it does crash with SOME clients. PLEASE HELP ME OUT !
    And another question: How do I get the channel ID and the client ID ?

  2. #2
    Join Date
    February 2017
    Location
    Kepler-186f
    Posts
    68
    You need to free the memory.
    Last edited by cydolo; October 14th, 2019 at 04:16 PM.

  3. #3
    Join Date
    November 2017
    Posts
    13
    I did this with all char* defined above but it does cause a crash to me if I click on myself

    part of code: https://hastebin.com/tedotopina.cpp

  4. #4
    Join Date
    February 2017
    Location
    Kepler-186f
    Posts
    68
    I do not know from where you get the buffersize 1048576
    Last edited by cydolo; October 14th, 2019 at 04:16 PM.

  5. #5
    Join Date
    November 2017
    Posts
    13
    Code: https://hastebin.com/apuwugeyep.m

    If I click on any channel I crash.
    And sometimes I crash if I click on clients.

  6. #6
    Join Date
    February 2017
    Location
    Kepler-186f
    Posts
    68
    you need to free the memory after snprintf.
    the reason why you crashed is because you are trying to free the memory that not has been written.
    Code:
    char* channelId = "Error";
    Last edited by cydolo; October 14th, 2019 at 04:17 PM.

  7. #7
    Join Date
    November 2017
    Posts
    13
    yes it really works. thank you man

    but I don't get how to get the "channelId" and "clientId" like in the ExtendedClientInfo design?

  8. #8
    Join Date
    November 2017
    Posts
    13
    okay xD found one client who still crashes me.
    Crash: The thread tried to continue execution after a noncontinuable exception occured.
    Code: https://hastebin.com/ozucunowor.m
    Client:
    2019-10-13 09:01:48.730673|ERROR |Plugin |1 |GlowingDreamer .♫♪:
    2019-10-13 09:01:48.730673|ERROR |Plugin |1 |L5SVyL6HH7IyG9j2ToS6eHsC/Rw=
    2019-10-13 09:01:48.730673|ERROR |Plugin |1 |253
    2019-10-13 09:01:48.730673|ERROR |Plugin |1 |1570950514
    2019-10-13 09:01:48.730673|ERROR |Plugin |1 |1

  9. #9
    Join Date
    February 2017
    Location
    Kepler-186f
    Posts
    68

  10. #10
    Join Date
    November 2017
    Posts
    13
    I copied the source code, it crash instantly everytime I tried to join a server
    I had to change some of the source code but it still crashes after 1-2 seconds after I join a server because "The thread tried to read from or write to a virtual adress for which it does not have the appropriate access."


    Is there a way that someone from the teamspeak team can help me with this issue?

  11. #11
    Join Date
    February 2017
    Location
    Kepler-186f
    Posts
    68
    I did that without your code. it works for me without any errors or crashes.

    https://hastebin.com/iwunosaqim.m
    Code:
    void ts3plugin_infoData(uint64 serverConnectionHandlerID, uint64 id, enum PluginItemType type, char** data) {
    	char* channel_name;
    	char* client_name;
    	char* client_uuid;
    	char* client_totalcon;
    	char* client_dbid;
    
    	/* For demonstration purpose, display the name of the currently selected server, channel or client. */
    	switch (type) {
    	case PLUGIN_SERVER: return;
    	case PLUGIN_CHANNEL:
    		if (ts3Functions.getChannelVariableAsString(serverConnectionHandlerID, id, CHANNEL_NAME, &channel_name) != ERROR_ok) {
    			printf("Error getting channel name\n");
    			return;
    		}
    		*data = (char*)malloc(INFODATA_BUFSIZE * sizeof(char));
    		snprintf(*data, INFODATA_BUFSIZE, "Name: %s\nID: %u", channel_name, id);
    		ts3Functions.freeMemory(channel_name);
    		return;
    	case PLUGIN_CLIENT:
    		if (ts3Functions.getClientVariableAsString(serverConnectionHandlerID, (anyID)id, CLIENT_NICKNAME, &client_name) != ERROR_ok) { printf("Error getting client nickname\n"); return; }
    		if (ts3Functions.getClientVariableAsString(serverConnectionHandlerID, (anyID)id, CLIENT_UNIQUE_IDENTIFIER, &client_uuid) != ERROR_ok) { printf("Error getting client uuid\n"); return; }
    		if (ts3Functions.getClientVariableAsString(serverConnectionHandlerID, (anyID)id, CLIENT_TOTALCONNECTIONS, &client_totalcon) != ERROR_ok) { printf("Error getting client totalconnections\n"); return; }
    		if (ts3Functions.getClientVariableAsString(serverConnectionHandlerID, (anyID)id, CLIENT_DATABASE_ID, &client_dbid) != ERROR_ok) { printf("Error getting client database\n"); return; }
    
    		
    		*data = (char*)malloc(INFODATA_BUFSIZE * sizeof(char));
    		snprintf(*data, INFODATA_BUFSIZE, "Name: %s\nID: %u\nUUID: %s\nDatabaseid: %s\nTotalconnections: %s", client_name, id, client_uuid, client_dbid, client_totalcon);
    		ts3Functions.freeMemory(client_name);
    		ts3Functions.freeMemory(client_uuid);
    		ts3Functions.freeMemory(client_totalcon);
    		ts3Functions.freeMemory(client_dbid);
    		return;
    	default:
    		printf("Invalid item type: %d\n", type);
    		data = NULL;  /* Ignore */
    		return;
    	}
    }

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [Resolved] teamspeak 3 application android crash crash crash
    By hycksou in forum Android
    Replies: 4
    Last Post: July 5th, 2017, 07:05 PM
  2. Crash after log in
    By cluster04 in forum Windows
    Replies: 0
    Last Post: February 23rd, 2017, 08:01 PM
  3. [Resolved] Users can crash all per crash
    By VinzK in forum Bug Reports [EN/DE]
    Replies: 34
    Last Post: April 26th, 2016, 03:47 PM
  4. Replies: 0
    Last Post: November 18th, 2014, 10:40 PM
  5. Replies: 11
    Last Post: April 19th, 2010, 12:51 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •