An error occurred on my MacBook running Mac OS X 10.5 Leopard the other day while I was importing pictures into iPhoto. About halfway through the image import, a dialog box popped up saying "An error occurred while trying to save your photo library. Some recent changes may be lost. Make sure your hard disk has enough space and that iPhoto is able to access the iPhoto Library."
My disk definitely wasn't full because I just upgraded the hard drive to 500GB following the instructions found here: 500GB MacBook Harddrive Upgrade for Under $100. In fact I checked just to make sure and there was still 285 GB of free space. I was worried that my iPhoto library was messed up despite not doing anything unordinary. A day later I got another system error when adding some other files to a folder in my home folder. It dawned on me then that there might be perhaps some upper limit per user account, and I might have reached it.
Solution: While the HD still had plenty of room, the user account had reached some limit set by the operating system. I created a new folder on the root directory of the HD and transferred several large files out of my home account into the new folder thereby freeing up space for the photos I wanted to import into iPhoto. Another solution would be to somehow change the allotted HD space per user account. Maybe it has something to do with FileVault as well??