Messaging broken 5.6.3.4 mysqli error

Permalink
Curious if anyone has experienced this before I begin digging for a solution. Initial c5 search yielded me nothing. In a nutshell I'm working to restrict who can message who(admin to all, all to admin only). My first thought was to see how a user might use url manipulation to message users they shouldn't. Of course, you can out of box.

I proceeded to message myself as user id 2. The message went through as though i had messaged user id 1, and now messaging is broken. Sending messages between 1 and 2 now yields the following error:

mysqli error: [1062: Duplicate entry '0-2-1' for key 'PRIMARY'] in EXECUTE("insert into UserPrivateMessagesTo (msgID, uID, uAuthorID, msgMailboxID, msgIsNew, msgIsUnread) values (0, '2', '1', -1, 1, 1)")

messaging between other users does not create an error. In the message lists you can see the total number of messages increments with sent/received messages, but the message lists are empty.

I'm guessing msgMailboxID being -1 is the issue.

Possibly a bug? Is anyone able to re-create this?
Any insights appreciated!

enlil
 
enlil replied on at Permalink Reply
enlil