Results 1 to 2 of 2
-
14-06-2012, 09:49 #1
-= TeamSpeak User =-
- Join Date
- Mar 2012
- Posts
- 18
channel_icon_id problem (out of range)
If i set icon 2682757409, server reports me channel_icon_id=-1612209887, but works correctly. Is it my problem or a bug? If not a bug, how correctly convert reported negative icon_id to icon_id i was asking to set (positive) to check if they are equal
I think it is int datatype range problem (signed int_4 \ unsigned int_4) which is limited to 2147483647, but when client uploads icon, it gives it name in unsigned int_4, and when I set channel_icon_id, I have to use unsigned int_4 icon_id, but when i ask for channel info, i receive signed int_4 value, so, I think, it is a bug.
3.0.5 amd64
Code:login *** *** use sid=1 channeledit cid=36 channel_icon_id=2682757409 channelinfo cid=36
--Code:error id=0 msg=ok (17 ms) error id=0 msg=ok (2 ms) error id=0 msg=ok (13 ms) pid=34 channel_name=WG\sAlly\sattacks channel_topic=WG_STATUS <....> channel_icon_id=-1612209887 error id=0 msg=ok (42 ms) Total: 74 ms
Simply, I have a PHP script that sheduled in a cron and changes channel names and icons depending on current WOW Tol-barad and Wintergrasp locations statuses.
For this problem I get current icon Id with this function:
Maybe there is a more right way? ^-)
Edit by a moderatorCode://Tested only on amd64 pratform! //PHP 5.3 //Example: // $s_icon_id = uint_cor($chan['channel_icon_id']); // string uint_cor(string) function uint_cor($s_int) { $i = floatval($s_int); if ($i < 0) return (string)bindec(substr(decbin($i),-32)); else return $s_int; }
Please no bump posts.
UPD. Please, say "Bugfix is planned" or "It's normal, it's not a bug because..."Last edited by dante696; 19-06-2012 at 09:49.
-
19-06-2012, 11:07 #2
-= TeamSpeak Team =-
- Join Date
- Jun 2008
- Posts
- 7,762
Thisi no bug, that need to be fixed, it's a normal behavior.
The Icons ID is genrated with a CRC32 check and result is a 32Bit unsigned value (0 up to 4.294.967.295) , but the server does use 32Bit signed(−2.147.483.648 up to 2.147.483.647).
The negative value appears, when the generated Icon ID is 2.147.483.648 or higher.---------------------------------------------------------
Please don't send me private support questions.
They belong into the forum and maybe other users have these questions/problems too.
TeamSpeak FAQ || What should i report, when i open a client thread? || Report and upload your Crashdump here
NPL License (Registration)
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Similar Threads
-
[Resolved] ServerQuery channel_icon_id problem
By devour in forum Linux / FreeBSDReplies: 1Last Post: 26-01-2012, 09:02 -
banning by ip range!
By Slicky456 in forum Server SupportReplies: 6Last Post: 08-05-2011, 17:56 -
IP Range Banning
By Confedorate in forum [TeamSpeak 2] Server SupportReplies: 2Last Post: 24-02-2005, 20:34


Reply With Quote