Fixed caching by passing in constant pointer to pointer to struct.