The trade menu allowed players to cheat by manipulating the amount of an item bought or sold (I won't get into details). I was able to reproduce the bug, and find the root cause. Now it should not allow for this kind of swindling to occur.