Fixed several bugs:

http://bugzilla.seng.uvic.ca/show_bug.cgi?id=675
http://bugzilla.seng.uvic.ca/show_bug.cgi?id=679
http://bugzilla.seng.uvic.ca/show_bug.cgi?id=671