Are you *sure* other people can update their pictures? Get somebody to try
My first worry is that the moodledata directory is in a bad place - its accessible by the web server which is a bad plan. If it wasn't for the fact that you say other stuff is working I would suggest that there is a permissions problem with that directory. There really isn't any reason that your file would not write and others will which is I why I am suggesting that you check others *really* are.