| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2009 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | package android.bluetooth; |
| 18 | |
| Jeff Sharkey | 5ba8bfc | 2021-04-16 09:53:23 -0600 | [diff] [blame] | 19 | import android.annotation.SuppressLint; |
| Artur Satayev | d8fe38c | 2019-12-10 17:47:52 +0000 | [diff] [blame] | 20 | import android.compat.annotation.UnsupportedAppUsage; |
| Nick Pelly | ee1402d | 2009-10-02 20:34:18 -0700 | [diff] [blame] | 21 | import android.os.Handler; |
| zzy | fab62db | 2012-04-03 19:48:32 -0700 | [diff] [blame] | 22 | import android.os.ParcelUuid; |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 23 | import android.util.Log; |
| Nick Pelly | ee1402d | 2009-10-02 20:34:18 -0700 | [diff] [blame] | 24 | |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 25 | import java.io.Closeable; |
| 26 | import java.io.IOException; |
| 27 | |
| 28 | /** |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 29 | * A listening Bluetooth socket. |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 30 | * |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 31 | * <p>The interface for Bluetooth Sockets is similar to that of TCP sockets: |
| 32 | * {@link java.net.Socket} and {@link java.net.ServerSocket}. On the server |
| 33 | * side, use a {@link BluetoothServerSocket} to create a listening server |
| Scott Main | beef809 | 2009-11-03 18:17:59 -0800 | [diff] [blame] | 34 | * socket. When a connection is accepted by the {@link BluetoothServerSocket}, |
| 35 | * it will return a new {@link BluetoothSocket} to manage the connection. |
| Jake Hamby | 04c7138 | 2010-09-21 13:39:53 -0700 | [diff] [blame] | 36 | * On the client side, use a single {@link BluetoothSocket} to both initiate |
| Scott Main | beef809 | 2009-11-03 18:17:59 -0800 | [diff] [blame] | 37 | * an outgoing connection and to manage the connection. |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 38 | * |
| Stanley Tng | 3b28545 | 2019-04-19 14:27:09 -0700 | [diff] [blame] | 39 | * <p>For Bluetooth BR/EDR, the most common type of socket is RFCOMM, which is the type supported by |
| 40 | * the Android APIs. RFCOMM is a connection-oriented, streaming transport over Bluetooth BR/EDR. It |
| 41 | * is also known as the Serial Port Profile (SPP). To create a listening |
| 42 | * {@link BluetoothServerSocket} that's ready for incoming Bluetooth BR/EDR connections, use {@link |
| 43 | * BluetoothAdapter#listenUsingRfcommWithServiceRecord |
| 44 | * BluetoothAdapter.listenUsingRfcommWithServiceRecord()}. |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 45 | * |
| Stanley Tng | 3b28545 | 2019-04-19 14:27:09 -0700 | [diff] [blame] | 46 | * <p>For Bluetooth LE, the socket uses LE Connection-oriented Channel (CoC). LE CoC is a |
| 47 | * connection-oriented, streaming transport over Bluetooth LE and has a credit-based flow control. |
| 48 | * Correspondingly, use {@link BluetoothAdapter#listenUsingL2capChannel |
| 49 | * BluetoothAdapter.listenUsingL2capChannel()} to create a listening {@link BluetoothServerSocket} |
| 50 | * that's ready for incoming Bluetooth LE CoC connections. For LE CoC, you can use {@link #getPsm()} |
| 51 | * to get the protocol/service multiplexer (PSM) value that the peer needs to use to connect to your |
| 52 | * socket. |
| 53 | * |
| 54 | * <p> After the listening {@link BluetoothServerSocket} is created, call {@link #accept()} to |
| 55 | * listen for incoming connection requests. This call will block until a connection is established, |
| 56 | * at which point, it will return a {@link BluetoothSocket} to manage the connection. Once the |
| 57 | * {@link BluetoothSocket} is acquired, it's a good idea to call {@link #close()} on the {@link |
| 58 | * BluetoothServerSocket} when it's no longer needed for accepting |
| 59 | * connections. Closing the {@link BluetoothServerSocket} will <em>not</em> close the returned |
| 60 | * {@link BluetoothSocket}. |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 61 | * |
| Scott Main | beef809 | 2009-11-03 18:17:59 -0800 | [diff] [blame] | 62 | * <p>{@link BluetoothServerSocket} is thread |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 63 | * safe. In particular, {@link #close} will always immediately abort ongoing |
| Scott Main | beef809 | 2009-11-03 18:17:59 -0800 | [diff] [blame] | 64 | * operations and close the server socket. |
| Nick Pelly | ed6f2ce | 2009-09-08 10:12:06 -0700 | [diff] [blame] | 65 | * |
| Joe Fernandez | da4e2ab | 2011-12-20 10:38:34 -0800 | [diff] [blame] | 66 | * <div class="special reference"> |
| 67 | * <h3>Developer Guides</h3> |
| 68 | * <p>For more information about using Bluetooth, read the |
| Marie Janssen | f242df2 | 2016-06-20 10:26:31 -0700 | [diff] [blame] | 69 | * <a href="{@docRoot}guide/topics/connectivity/bluetooth.html">Bluetooth</a> developer guide.</p> |
| Joe Fernandez | da4e2ab | 2011-12-20 10:38:34 -0800 | [diff] [blame] | 70 | * </div> |
| 71 | * |
| Scott Main | beef809 | 2009-11-03 18:17:59 -0800 | [diff] [blame] | 72 | * {@see BluetoothSocket} |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 73 | */ |
| Jeff Sharkey | 5ba8bfc | 2021-04-16 09:53:23 -0600 | [diff] [blame] | 74 | @SuppressLint("AndroidFrameworkBluetoothPermission") |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 75 | public final class BluetoothServerSocket implements Closeable { |
| Nick Pelly | 4cd2cd9 | 2009-09-02 11:51:35 -0700 | [diff] [blame] | 76 | |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 77 | private static final String TAG = "BluetoothServerSocket"; |
| Ugo Yu | b6dc15a | 2022-12-28 20:18:00 +0800 | [diff] [blame^] | 78 | private static final boolean DBG = Log.isLoggable(TAG, Log.DEBUG); |
| Andrei Onea | 147146f | 2019-06-17 11:26:14 +0100 | [diff] [blame] | 79 | @UnsupportedAppUsage(publicAlternatives = "Use public {@link BluetoothServerSocket} API " |
| 80 | + "instead.") |
| Nick Pelly | 2d66488 | 2009-08-14 18:33:38 -0700 | [diff] [blame] | 81 | /*package*/ final BluetoothSocket mSocket; |
| Nick Pelly | ee1402d | 2009-10-02 20:34:18 -0700 | [diff] [blame] | 82 | private Handler mHandler; |
| 83 | private int mMessage; |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 84 | private int mChannel; |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 85 | |
| 86 | /** |
| 87 | * Construct a socket for incoming connections. |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 88 | * |
| 89 | * @param type type of socket |
| 90 | * @param auth require the remote device to be authenticated |
| Nick Pelly | cb32d7c | 2009-06-02 15:57:18 -0700 | [diff] [blame] | 91 | * @param encrypt require the connection to be encrypted |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 92 | * @param port remote port |
| 93 | * @throws IOException On error, for example Bluetooth not available, or insufficient |
| 94 | * privileges |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 95 | */ |
| Nick Pelly | 2d66488 | 2009-08-14 18:33:38 -0700 | [diff] [blame] | 96 | /*package*/ BluetoothServerSocket(int type, boolean auth, boolean encrypt, int port) |
| Nick Pelly | cb32d7c | 2009-06-02 15:57:18 -0700 | [diff] [blame] | 97 | throws IOException { |
| Ben Dodson | 48d0cca | 2011-07-08 14:36:42 -0700 | [diff] [blame] | 98 | mChannel = port; |
| Nick Pelly | 07b84cb | 2009-10-07 07:44:03 +0200 | [diff] [blame] | 99 | mSocket = new BluetoothSocket(type, -1, auth, encrypt, null, port, null); |
| Casper Bonde | 60d77c2 | 2015-04-21 13:12:05 +0200 | [diff] [blame] | 100 | if (port == BluetoothAdapter.SOCKET_CHANNEL_AUTO_STATIC_NO_SDP) { |
| 101 | mSocket.setExcludeSdp(true); |
| 102 | } |
| 103 | } |
| 104 | |
| 105 | /** |
| 106 | * Construct a socket for incoming connections. |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 107 | * |
| 108 | * @param type type of socket |
| 109 | * @param auth require the remote device to be authenticated |
| Casper Bonde | 60d77c2 | 2015-04-21 13:12:05 +0200 | [diff] [blame] | 110 | * @param encrypt require the connection to be encrypted |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 111 | * @param port remote port |
| Jeff Sharkey | c5386af | 2020-09-11 14:57:21 -0600 | [diff] [blame] | 112 | * @param mitm enforce person-in-the-middle protection for authentication. |
| Casper Bonde | 9127601 | 2015-05-08 14:32:24 +0200 | [diff] [blame] | 113 | * @param min16DigitPin enforce a minimum length of 16 digits for a sec mode 2 connection |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 114 | * @throws IOException On error, for example Bluetooth not available, or insufficient |
| 115 | * privileges |
| Casper Bonde | 60d77c2 | 2015-04-21 13:12:05 +0200 | [diff] [blame] | 116 | */ |
| 117 | /*package*/ BluetoothServerSocket(int type, boolean auth, boolean encrypt, int port, |
| Casper Bonde | 9127601 | 2015-05-08 14:32:24 +0200 | [diff] [blame] | 118 | boolean mitm, boolean min16DigitPin) |
| Casper Bonde | 60d77c2 | 2015-04-21 13:12:05 +0200 | [diff] [blame] | 119 | throws IOException { |
| 120 | mChannel = port; |
| Casper Bonde | 9127601 | 2015-05-08 14:32:24 +0200 | [diff] [blame] | 121 | mSocket = new BluetoothSocket(type, -1, auth, encrypt, null, port, null, mitm, |
| 122 | min16DigitPin); |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 123 | if (port == BluetoothAdapter.SOCKET_CHANNEL_AUTO_STATIC_NO_SDP) { |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 124 | mSocket.setExcludeSdp(true); |
| 125 | } |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 126 | } |
| 127 | |
| 128 | /** |
| zzy | fab62db | 2012-04-03 19:48:32 -0700 | [diff] [blame] | 129 | * Construct a socket for incoming connections. |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 130 | * |
| 131 | * @param type type of socket |
| 132 | * @param auth require the remote device to be authenticated |
| zzy | fab62db | 2012-04-03 19:48:32 -0700 | [diff] [blame] | 133 | * @param encrypt require the connection to be encrypted |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 134 | * @param uuid uuid |
| 135 | * @throws IOException On error, for example Bluetooth not available, or insufficient |
| 136 | * privileges |
| zzy | fab62db | 2012-04-03 19:48:32 -0700 | [diff] [blame] | 137 | */ |
| 138 | /*package*/ BluetoothServerSocket(int type, boolean auth, boolean encrypt, ParcelUuid uuid) |
| 139 | throws IOException { |
| 140 | mSocket = new BluetoothSocket(type, -1, auth, encrypt, null, -1, uuid); |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 141 | // TODO: This is the same as mChannel = -1 - is this intentional? |
| zzy | fab62db | 2012-04-03 19:48:32 -0700 | [diff] [blame] | 142 | mChannel = mSocket.getPort(); |
| 143 | } |
| 144 | |
| 145 | |
| 146 | /** |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 147 | * Block until a connection is established. |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 148 | * <p>Returns a connected {@link BluetoothSocket} on successful connection. |
| 149 | * <p>Once this call returns, it can be called again to accept subsequent |
| 150 | * incoming connections. |
| 151 | * <p>{@link #close} can be used to abort this call from another thread. |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 152 | * |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 153 | * @return a connected {@link BluetoothSocket} |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 154 | * @throws IOException on error, for example this call was aborted, or timeout |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 155 | */ |
| 156 | public BluetoothSocket accept() throws IOException { |
| 157 | return accept(-1); |
| 158 | } |
| 159 | |
| 160 | /** |
| 161 | * Block until a connection is established, with timeout. |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 162 | * <p>Returns a connected {@link BluetoothSocket} on successful connection. |
| 163 | * <p>Once this call returns, it can be called again to accept subsequent |
| 164 | * incoming connections. |
| 165 | * <p>{@link #close} can be used to abort this call from another thread. |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 166 | * |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 167 | * @return a connected {@link BluetoothSocket} |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 168 | * @throws IOException on error, for example this call was aborted, or timeout |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 169 | */ |
| 170 | public BluetoothSocket accept(int timeout) throws IOException { |
| Nick Pelly | 4cd2cd9 | 2009-09-02 11:51:35 -0700 | [diff] [blame] | 171 | return mSocket.accept(timeout); |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 172 | } |
| 173 | |
| 174 | /** |
| Nick Pelly | 753da53 | 2009-08-19 11:00:00 -0700 | [diff] [blame] | 175 | * Immediately close this socket, and release all associated resources. |
| 176 | * <p>Causes blocked calls on this socket in other threads to immediately |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 177 | * throw an IOException. |
| Scott Main | a7848ce | 2009-11-19 17:00:19 -0800 | [diff] [blame] | 178 | * <p>Closing the {@link BluetoothServerSocket} will <em>not</em> |
| 179 | * close any {@link BluetoothSocket} received from {@link #accept()}. |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 180 | */ |
| 181 | public void close() throws IOException { |
| Stanley Tng | d67d5e4 | 2017-11-22 16:04:40 -0800 | [diff] [blame] | 182 | if (DBG) Log.d(TAG, "BluetoothServerSocket:close() called. mChannel=" + mChannel); |
| Nick Pelly | ee1402d | 2009-10-02 20:34:18 -0700 | [diff] [blame] | 183 | synchronized (this) { |
| 184 | if (mHandler != null) { |
| 185 | mHandler.obtainMessage(mMessage).sendToTarget(); |
| 186 | } |
| 187 | } |
| Nick Pelly | 4cd2cd9 | 2009-09-02 11:51:35 -0700 | [diff] [blame] | 188 | mSocket.close(); |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 189 | } |
| Nick Pelly | ee1402d | 2009-10-02 20:34:18 -0700 | [diff] [blame] | 190 | |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 191 | /*package*/ |
| 192 | synchronized void setCloseHandler(Handler handler, int message) { |
| Nick Pelly | ee1402d | 2009-10-02 20:34:18 -0700 | [diff] [blame] | 193 | mHandler = handler; |
| 194 | mMessage = message; |
| 195 | } |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 196 | |
| Jack He | 9e045d2 | 2017-08-22 21:21:23 -0700 | [diff] [blame] | 197 | /*package*/ void setServiceName(String serviceName) { |
| 198 | mSocket.setServiceName(serviceName); |
| zzy | fab62db | 2012-04-03 19:48:32 -0700 | [diff] [blame] | 199 | } |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 200 | |
| Ben Dodson | 48d0cca | 2011-07-08 14:36:42 -0700 | [diff] [blame] | 201 | /** |
| 202 | * Returns the channel on which this socket is bound. |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 203 | * |
| Ben Dodson | 48d0cca | 2011-07-08 14:36:42 -0700 | [diff] [blame] | 204 | * @hide |
| 205 | */ |
| 206 | public int getChannel() { |
| 207 | return mChannel; |
| 208 | } |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 209 | |
| 210 | /** |
| Stanley Tng | d67d5e4 | 2017-11-22 16:04:40 -0800 | [diff] [blame] | 211 | * Returns the assigned dynamic protocol/service multiplexer (PSM) value for the listening L2CAP |
| 212 | * Connection-oriented Channel (CoC) server socket. This server socket must be returned by the |
| Xin Li | 10802fb | 2019-02-13 22:36:25 -0800 | [diff] [blame] | 213 | * {@link BluetoothAdapter#listenUsingL2capChannel()} or {@link |
| 214 | * BluetoothAdapter#listenUsingInsecureL2capChannel()}. The returned value is undefined if this |
| Stanley Tng | d67d5e4 | 2017-11-22 16:04:40 -0800 | [diff] [blame] | 215 | * method is called on non-L2CAP server sockets. |
| 216 | * |
| 217 | * @return the assigned PSM or LE_PSM value depending on transport |
| Stanley Tng | d67d5e4 | 2017-11-22 16:04:40 -0800 | [diff] [blame] | 218 | */ |
| 219 | public int getPsm() { |
| 220 | return mChannel; |
| 221 | } |
| 222 | |
| 223 | /** |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 224 | * Sets the channel on which future sockets are bound. |
| 225 | * Currently used only when a channel is auto generated. |
| 226 | */ |
| 227 | /*package*/ void setChannel(int newChannel) { |
| 228 | /* TODO: From a design/architecture perspective this is wrong. |
| 229 | * The bind operation should be conducted through this class |
| 230 | * and the resulting port should be kept in mChannel, and |
| 231 | * not set from BluetoothAdapter. */ |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 232 | if (mSocket != null) { |
| 233 | if (mSocket.getPort() != newChannel) { |
| 234 | Log.w(TAG, "The port set is different that the underlying port. mSocket.getPort(): " |
| 235 | + mSocket.getPort() + " requested newChannel: " + newChannel); |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 236 | } |
| 237 | } |
| 238 | mChannel = newChannel; |
| 239 | } |
| 240 | |
| 241 | @Override |
| 242 | public String toString() { |
| 243 | StringBuilder sb = new StringBuilder(); |
| 244 | sb.append("ServerSocket: Type: "); |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 245 | switch (mSocket.getConnectionType()) { |
| 246 | case BluetoothSocket.TYPE_RFCOMM: { |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 247 | sb.append("TYPE_RFCOMM"); |
| 248 | break; |
| 249 | } |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 250 | case BluetoothSocket.TYPE_L2CAP: { |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 251 | sb.append("TYPE_L2CAP"); |
| 252 | break; |
| 253 | } |
| Stanley Tng | d67d5e4 | 2017-11-22 16:04:40 -0800 | [diff] [blame] | 254 | case BluetoothSocket.TYPE_L2CAP_LE: { |
| 255 | sb.append("TYPE_L2CAP_LE"); |
| 256 | break; |
| 257 | } |
| Jack He | 910201b | 2017-08-22 16:06:54 -0700 | [diff] [blame] | 258 | case BluetoothSocket.TYPE_SCO: { |
| Casper Bonde | c0a7c93 | 2015-04-09 09:24:48 +0200 | [diff] [blame] | 259 | sb.append("TYPE_SCO"); |
| 260 | break; |
| 261 | } |
| 262 | } |
| 263 | sb.append(" Channel: ").append(mChannel); |
| 264 | return sb.toString(); |
| 265 | } |
| Nick Pelly | 53f441b | 2009-05-26 19:13:43 -0700 | [diff] [blame] | 266 | } |