I won't go in details since I already discussed about this on MediaWiki's IRC room. I'll just say this: My gender on Wikipedia is set to male. I checked all types of logs and every single user is displayed in male form (regardless of the gender). When I change my gender to female, it's a different story. Then it depends on type of the action. All the messages in block, protection and upload logs are displayed in female forms, and all the other log messages are in male forms.
Epiphany: I just logged in some pastebin site after a while and found a list of log messages I uploaded before, without username variables. And those messages are displayed wrongly on Serbian Wikipedia! I finally realized what was this fuzz all about. You need to include username variables to these messages in order for them to work: http://tinypaste.com/8660f. I remember this was reported a couple of times before, but no progress was made since.