Current time: 03-18-2010, 10:36 AM Hello There, Guest! (LoginRegister)


 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[F] Bug in setting oldgroup in task (expire bans)
09-10-2008, 09:23 AM
Post: #1
[F] Bug in setting oldgroup in task (expire bans)
MyBB 1.4.1.
I have found possible bug while reviewing code - I did not test it however.

File: inc/tasks/usercleanup.php, code:
PHP Code:
    // Expire bans
    
$query $db->simple_select("banned""*""lifted!=0 AND lifted<".TIME_NOW);
    while(
$ban $db->fetch_array($query))
    {
        
$updated_user = array(
            
"usergroup" => $ban['oldgroup'],
            
"additionalgroups" => $ban['oldadditionalgroups'],
            
"displaygroup" => $ban['displaygroup']
        );
        
$db->update_query("users"$updated_user"uid='{$ban['uid']}'");
        
$db->delete_query("banned""uid='{$ban['uid']}'");
    } 

This line:
PHP Code:
"displaygroup" => $ban['displaygroup'

should be:
PHP Code:
"displaygroup" => $ban['olddisplaygroup'
?

www.kozik.net.pl
- So... Maybe you shouldn't have hacked it.
- And why don't you try not breathing. Hurts, dunnit. (userfriendly.org)
Visit this user's website Find all posts by this user
09-11-2008, 12:22 AM
Post: #2
[F] Bug in setting oldgroup in task (expire bans)
Thank you for your bug report.

This bug has been fixed in our internal code repository. Please note that the problem will not be fixed here until these forums are updated.

[Image: ryangordon.png]
My Blog - My Mods
Visit this user's website Find all posts by this user


Forum Jump: