#include <iostream>
struct gatt_db_attribute {};
bool gatt_db_service_set_active(struct gatt_db_attribute *attrib, bool active, int fd=0);
bool gatt_db_service_set_active(struct gatt_db_attribute *attrib, bool active, int fd=0);
int main() {
gatt_db_service_set_active(NULL, true);
gatt_db_service_set_active(NULL, true, 3);
}
bool gatt_db_service_set_active(struct gatt_db_attribute *attrib, bool active, int fd) {
// stuff
}
I2luY2x1ZGUgPGlvc3RyZWFtPgoKc3RydWN0IGdhdHRfZGJfYXR0cmlidXRlIHt9OwoKYm9vbCBnYXR0X2RiX3NlcnZpY2Vfc2V0X2FjdGl2ZShzdHJ1Y3QgZ2F0dF9kYl9hdHRyaWJ1dGUgKmF0dHJpYiwgYm9vbCBhY3RpdmUsIGludCBmZD0wKTsKYm9vbCBnYXR0X2RiX3NlcnZpY2Vfc2V0X2FjdGl2ZShzdHJ1Y3QgZ2F0dF9kYl9hdHRyaWJ1dGUgKmF0dHJpYiwgYm9vbCBhY3RpdmUsIGludCBmZD0wKTsKCgppbnQgbWFpbigpIHsKCWdhdHRfZGJfc2VydmljZV9zZXRfYWN0aXZlKE5VTEwsIHRydWUpOwoKCWdhdHRfZGJfc2VydmljZV9zZXRfYWN0aXZlKE5VTEwsIHRydWUsIDMpOwoKfQoKYm9vbCBnYXR0X2RiX3NlcnZpY2Vfc2V0X2FjdGl2ZShzdHJ1Y3QgZ2F0dF9kYl9hdHRyaWJ1dGUgKmF0dHJpYiwgYm9vbCBhY3RpdmUsIGludCBmZCkgewoJLy8gc3R1ZmYKfQo=
prog.cpp:6:88: error: default argument given for parameter 3 of 'bool gatt_db_service_set_active(gatt_db_attribute*, bool, int)' [-fpermissive]
bool gatt_db_service_set_active(struct gatt_db_attribute *attrib, bool active, int fd=0);
^
prog.cpp:5:6: note: previous specification in 'bool gatt_db_service_set_active(gatt_db_attribute*, bool, int)' here
bool gatt_db_service_set_active(struct gatt_db_attribute *attrib, bool active, int fd=0);
^