The Usual Tech Ramblings

Productivity out of work... yay

For some reason, despite the fact that work is going like hell at the moment, with all kinds of crazy stuff happening, my out of work projects are thriving.

Take SquirrelMail for example. Cor Bosman from XS4ALL released SquirrelMail 1.4.5 to their user base after extensive testing, and internal enhancements. This has generated a whole bunch of feedback and allowed us to get a bunch of bug fixing done. In the last 3 days, I think I’ve made over 30 cvs commits.

I also fixed a long standing bug in the GPG plugin for SquirrelMail today. It was a minor documentation issue, and code misstake. A simple case of assuming strrpos did the same as strpos. In general, it does, except strrpos only accepts one character for the needle. This resulted in a case of matching nearly every attachment to verify with gpg. To fix, it was a case of changing this (line 211 in plugins/gpg/setup.php):

if ((strrpos($filename,".asc") == (strlen($filename)-4)) 
or (strrpos($filename,".pgp") == (strlen($filename)-4))) {

To this:

if ((strpos($filename,".asc") == (strlen($filename)-4)) 
or (strpos($filename,".pgp") == (strlen($filename)-4))) {

Code still works as expected, and no more issue of gpg checking all attachments to see if they are encrypted.

So, it’s been very productive for me this week, lets hope it continues. I’m planning on pushing SquirrelMail 1.4.6 out by Christmas.