Passing by address

I am trying to pass a value's address to a void function. I am getting an error in DevC++

"invalid initialization of non-const reference of type 'double&' from a temporary of type 'double*'"
and
"in passing argument 2 of `void getCommission(double, double&)' "

Can anyone tell me what this means? My function prototype looks like this:

void getCommission(double sales, double &commission);

and my call in the main function reads:

getCommission(sales, &commission);

Any help will be greatly appreciated. Thanks!
Remove the ampersand from the function call. That should do it.
Do'oh. Thx
Topic archived. No new replies allowed.