Fake input: missing input device fake struct free

This commit is contained in:
Claudio Takahasi 2007-02-23 18:26:47 +00:00
parent 2957490728
commit e977c52ef2

View File

@ -124,6 +124,8 @@ static void input_device_free(struct input_device *idev)
return;
if (idev->hidp.rd_data)
free(idev->hidp.rd_data);
if (idev->fake)
free(idev->fake);
free(idev);
}
@ -1312,6 +1314,8 @@ static void headset_record_reply(DBusPendingCall *call, void *data)
memset(idev->fake, 0, sizeof(struct fake_input));
idev->fake->ch = ch;
/* FIXME: Store the fake input data */
path = create_input_path(idev->major, idev->minor);
if (register_input_device(pr->conn, idev, path) < 0) {
error("D-Bus path registration failed:%s", path);