Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-10950

Deleting user with undelivered PMs causes SQL error

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.0.11-RC1
    • Fix Version/s: 3.0.11-RC2
    • Component/s: ACP
    • Labels:
      None

      Description

      When attempting to delete a user who has undelivered PMs, a SQL error occurs because a user ID is not provided to the query.

      General Error
      SQL ERROR [ mysqli ]
       
      You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 4 [1064]
       
      SQL
       
      UPDATE phpbb_users SET user_new_privmsg = user_new_privmsg - 1, user_unread_privmsg = user_unread_privmsg - 1 WHERE user_id = 
       
      BACKTRACE
       
      FILE: (not given by php)
      LINE: (not given by php)
      CALL: msg_handler()
       
      FILE: [ROOT]/includes/db/dbal.php
      LINE: 757
      CALL: trigger_error()
       
      FILE: [ROOT]/includes/db/mysqli.php
      LINE: 182
      CALL: dbal->sql_error()
       
      FILE: [ROOT]/includes/functions_privmsgs.php
      LINE: 1193
      CALL: dbal_mysqli->sql_query()
       
      FILE: [ROOT]/includes/functions_user.php
      LINE: 536
      CALL: phpbb_delete_user_pms()
       
      FILE: [ROOT]/includes/acp/acp_users.php
      LINE: 198
      CALL: user_delete()
       
      FILE: [ROOT]/includes/functions_module.php
      LINE: 507
      CALL: acp_users->main()
       
      FILE: [ROOT]/adm/index.php
      LINE: 75
      CALL: p_master->load_active()

      This appears to be caused by PHPBB3-10605.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                nickvergessen Joas Schilling
                Reporter:
                Noxwizard Patrick Webster
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: