Fixed wrongly used const pointer