summaryrefslogtreecommitdiffstats
path: root/chrome/browser/chromeos/bluetooth/bluetooth_utils.h
diff options
context:
space:
mode:
authorbryeung@chromium.org <bryeung@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-27 22:22:22 +0000
committerbryeung@chromium.org <bryeung@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-27 22:22:22 +0000
commit98ae4a3d3ca74c8de31122951d54709b57faff08 (patch)
tree4346fb444da4448154cd0de40aceca9edd743167 /chrome/browser/chromeos/bluetooth/bluetooth_utils.h
parent66a7c0cd84eb5303ba95f4be9f633b31b1cf4722 (diff)
downloadchromium_src-98ae4a3d3ca74c8de31122951d54709b57faff08.zip
chromium_src-98ae4a3d3ca74c8de31122951d54709b57faff08.tar.gz
chromium_src-98ae4a3d3ca74c8de31122951d54709b57faff08.tar.bz2
Fix the semantics of str2ba.
This was originally written to correspond to strtoba, which places the pairs of bytes in the wrong order for calls to connect(). TEST=updated unit test BUG=none Review URL: http://codereview.chromium.org/10253013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@134373 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/chromeos/bluetooth/bluetooth_utils.h')
-rw-r--r--chrome/browser/chromeos/bluetooth/bluetooth_utils.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/chrome/browser/chromeos/bluetooth/bluetooth_utils.h b/chrome/browser/chromeos/bluetooth/bluetooth_utils.h
index 2174037..09d0648 100644
--- a/chrome/browser/chromeos/bluetooth/bluetooth_utils.h
+++ b/chrome/browser/chromeos/bluetooth/bluetooth_utils.h
@@ -16,6 +16,8 @@ namespace bluetooth_utils {
// Converts a bluetooth address in the format "B0:D0:9C:0F:3A:2D" into a
// bdaddr_t struct. Returns true on success, false on failure. The contents
// of |out_address| are zeroed on failure.
+// Note that the order is reversed upon conversion. For example,
+// "B0:D0:9C:0F:3A:2D" -> {"0x2d", "0x3a", "0x0f", "0x9c", "0xd0", "0xb0"}
bool str2ba(const std::string& in_address, bdaddr_t* out_address);
} // namespace bluetooth_utils