fixing issues with using rand() by switching to openacs proc random