* [Bluez-devel] hci_send_req and EVT_CMD_STATUS
@ 2005-10-23 21:06 Johan Hedberg
2005-10-23 21:26 ` Marcel Holtmann
0 siblings, 1 reply; 2+ messages in thread
From: Johan Hedberg @ 2005-10-23 21:06 UTC (permalink / raw)
To: bluez-devel
[-- Attachment #1: Type: text/plain, Size: 394 bytes --]
Hi Marcel,
I see that you changed hci_send_req so that it will never return
cmd_status events with non-zero status (instead the function fails with
EIO). If this was intentional (the fix I sent would have allowed getting
the cmd status event in all circumstanses), please apply the attached
patch since checking for rp.status after hci_send_req has successfully
returned is unecessary.
Johan
[-- Attachment #2: cmd-status.patch --]
[-- Type: text/plain, Size: 1111 bytes --]
Index: dbus.c
===================================================================
RCS file: /cvsroot/bluez/utils/hcid/dbus.c,v
retrieving revision 1.31
diff -u -r1.31 dbus.c
--- dbus.c 22 Oct 2005 13:03:41 -0000 1.31
+++ dbus.c 23 Oct 2005 19:55:39 -0000
@@ -1374,12 +1374,6 @@
goto failed;
}
- if (rp.status) {
- syslog(LOG_ERR, "Inquiry command failed with status 0x%02X", rp.status);
- reply = bluez_new_failure_msg(msg, BLUEZ_ESYSTEM_OFFSET + EIO);
- goto failed;
- }
-
reply = dbus_message_new_method_return(msg);
failed:
@@ -1496,12 +1490,6 @@
goto failed;
}
- if (rp.status) {
- syslog(LOG_ERR, "Remote name command failed with status 0x%02X", rp.status);
- reply = bluez_new_failure_msg(msg, BLUEZ_ESYSTEM_OFFSET + EIO);
- goto failed;
- }
-
reply = dbus_message_new_method_return(msg);
failed:
@@ -1655,12 +1643,6 @@
goto failed;
}
- if (rp.status) {
- syslog(LOG_ERR, "Authentication command failed with status 0x%02X", rp.status);
- reply = bluez_new_failure_msg(msg, BLUEZ_ESYSTEM_OFFSET + EIO);
- goto failed;
- }
-
failed:
if (sock >= 0)
close(sock);
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Bluez-devel] hci_send_req and EVT_CMD_STATUS
2005-10-23 21:06 [Bluez-devel] hci_send_req and EVT_CMD_STATUS Johan Hedberg
@ 2005-10-23 21:26 ` Marcel Holtmann
0 siblings, 0 replies; 2+ messages in thread
From: Marcel Holtmann @ 2005-10-23 21:26 UTC (permalink / raw)
To: bluez-devel
Hi Johan,
> I see that you changed hci_send_req so that it will never return
> cmd_status events with non-zero status (instead the function fails with
> EIO). If this was intentional (the fix I sent would have allowed getting
> the cmd status event in all circumstanses), please apply the attached
> patch since checking for rp.status after hci_send_req has successfully
> returned is unecessary.
I didn't thought that much about it, but since you mentioned it, yes it
was intentional. The patch is in the CVS now.
Regards
Marcel
-------------------------------------------------------
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-10-23 21:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-10-23 21:06 [Bluez-devel] hci_send_req and EVT_CMD_STATUS Johan Hedberg
2005-10-23 21:26 ` Marcel Holtmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).