I’m guessing you meant integer(c_int). c_ptr is not a valid kind value for integer.
integer(c_int)
c_ptr
integer