added some prototype functions