Dan Albert | 7664901 | 2015-02-24 15:51:19 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2015 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 | |
Dan Albert | 3313426 | 2015-03-19 15:21:08 -0700 | [diff] [blame] | 17 | #define TRACE_TAG TRACE_ADB |
| 18 | |
| 19 | #include "sysdeps.h" |
| 20 | #include "adb_client.h" |
| 21 | |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 22 | #include <errno.h> |
| 23 | #include <limits.h> |
| 24 | #include <stdarg.h> |
Dan Albert | 7664901 | 2015-02-24 15:51:19 -0800 | [diff] [blame] | 25 | #include <stdio.h> |
| 26 | #include <stdlib.h> |
| 27 | #include <string.h> |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 28 | #include <sys/stat.h> |
Dan Albert | 7664901 | 2015-02-24 15:51:19 -0800 | [diff] [blame] | 29 | #include <sys/types.h> |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 30 | |
Elliott Hughes | 9309ecb | 2015-04-27 14:20:17 -0700 | [diff] [blame] | 31 | #include <string> |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 32 | #include <vector> |
| 33 | |
| 34 | #include <base/stringprintf.h> |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 35 | #include <base/strings.h> |
Elliott Hughes | 9309ecb | 2015-04-27 14:20:17 -0700 | [diff] [blame] | 36 | |
Dan Albert | cc731cc | 2015-02-24 21:26:58 -0800 | [diff] [blame] | 37 | #include "adb_io.h" |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 38 | |
Elliott Hughes | 3bd73c1 | 2015-05-05 13:10:43 -0700 | [diff] [blame] | 39 | static TransportType __adb_transport = kTransportAny; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 40 | static const char* __adb_serial = NULL; |
| 41 | |
Stefan Hilzinger | d0eacb8 | 2010-04-19 12:21:12 +0100 | [diff] [blame] | 42 | static int __adb_server_port = DEFAULT_ADB_PORT; |
Matt Gumbel | d7b3308 | 2012-11-14 10:16:17 -0800 | [diff] [blame] | 43 | static const char* __adb_server_name = NULL; |
Stefan Hilzinger | d0eacb8 | 2010-04-19 12:21:12 +0100 | [diff] [blame] | 44 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 45 | static std::string perror_str(const char* msg) { |
| 46 | return android::base::StringPrintf("%s: %s", msg, strerror(errno)); |
| 47 | } |
| 48 | |
| 49 | static bool ReadProtocolString(int fd, std::string* s, std::string* error) { |
| 50 | char buf[5]; |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 51 | if (!ReadFdExactly(fd, buf, 4)) { |
| 52 | *error = perror_str("protocol fault (couldn't read status length)"); |
| 53 | return false; |
| 54 | } |
| 55 | buf[4] = 0; |
| 56 | |
| 57 | unsigned long len = strtoul(buf, 0, 16); |
Elliott Hughes | e67f1f8 | 2015-04-30 17:32:03 -0700 | [diff] [blame] | 58 | s->resize(len, '\0'); |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 59 | if (!ReadFdExactly(fd, &(*s)[0], len)) { |
| 60 | *error = perror_str("protocol fault (couldn't read status message)"); |
| 61 | return false; |
| 62 | } |
| 63 | |
| 64 | return true; |
| 65 | } |
| 66 | |
Elliott Hughes | 3bd73c1 | 2015-05-05 13:10:43 -0700 | [diff] [blame] | 67 | void adb_set_transport(TransportType type, const char* serial) |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 68 | { |
| 69 | __adb_transport = type; |
| 70 | __adb_serial = serial; |
| 71 | } |
| 72 | |
Stefan Hilzinger | d0eacb8 | 2010-04-19 12:21:12 +0100 | [diff] [blame] | 73 | void adb_set_tcp_specifics(int server_port) |
| 74 | { |
| 75 | __adb_server_port = server_port; |
| 76 | } |
| 77 | |
Matt Gumbel | d7b3308 | 2012-11-14 10:16:17 -0800 | [diff] [blame] | 78 | void adb_set_tcp_name(const char* hostname) |
| 79 | { |
| 80 | __adb_server_name = hostname; |
| 81 | } |
| 82 | |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 83 | static int switch_socket_transport(int fd, std::string* error) { |
Elliott Hughes | 9309ecb | 2015-04-27 14:20:17 -0700 | [diff] [blame] | 84 | std::string service; |
| 85 | if (__adb_serial) { |
| 86 | service += "host:transport:"; |
| 87 | service += __adb_serial; |
| 88 | } else { |
Dan Albert | bac3474 | 2015-02-25 17:51:28 -0800 | [diff] [blame] | 89 | const char* transport_type = "???"; |
Elliott Hughes | 9309ecb | 2015-04-27 14:20:17 -0700 | [diff] [blame] | 90 | switch (__adb_transport) { |
| 91 | case kTransportUsb: |
| 92 | transport_type = "transport-usb"; |
| 93 | break; |
| 94 | case kTransportLocal: |
| 95 | transport_type = "transport-local"; |
| 96 | break; |
| 97 | case kTransportAny: |
| 98 | transport_type = "transport-any"; |
| 99 | break; |
| 100 | case kTransportHost: |
| 101 | // no switch necessary |
| 102 | return 0; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 103 | } |
Elliott Hughes | 9309ecb | 2015-04-27 14:20:17 -0700 | [diff] [blame] | 104 | service += "host:"; |
| 105 | service += transport_type; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 106 | } |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 107 | |
Elliott Hughes | e67f1f8 | 2015-04-30 17:32:03 -0700 | [diff] [blame] | 108 | if (!SendProtocolString(fd, service)) { |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 109 | *error = perror_str("write failure during connection"); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 110 | adb_close(fd); |
| 111 | return -1; |
| 112 | } |
| 113 | D("Switch transport in progress\n"); |
| 114 | |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 115 | if (!adb_status(fd, error)) { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 116 | adb_close(fd); |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 117 | D("Switch transport failed: %s\n", error->c_str()); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 118 | return -1; |
| 119 | } |
| 120 | D("Switch transport success\n"); |
| 121 | return 0; |
| 122 | } |
| 123 | |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 124 | bool adb_status(int fd, std::string* error) { |
| 125 | char buf[5]; |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 126 | if (!ReadFdExactly(fd, buf, 4)) { |
| 127 | *error = perror_str("protocol fault (couldn't read status)"); |
| 128 | return false; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 129 | } |
| 130 | |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 131 | if (!memcmp(buf, "OKAY", 4)) { |
| 132 | return true; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 133 | } |
| 134 | |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 135 | if (memcmp(buf, "FAIL", 4)) { |
| 136 | *error = android::base::StringPrintf("protocol fault (status %02x %02x %02x %02x?!)", |
| 137 | buf[0], buf[1], buf[2], buf[3]); |
| 138 | return false; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 139 | } |
| 140 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 141 | ReadProtocolString(fd, error, error); |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 142 | return false; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 143 | } |
| 144 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 145 | int _adb_connect(const std::string& service, std::string* error) { |
| 146 | D("_adb_connect: %s\n", service.c_str()); |
| 147 | if (service.empty() || service.size() > 1024) { |
Spencer Low | 6001c87 | 2015-05-13 00:02:55 -0700 | [diff] [blame] | 148 | *error = android::base::StringPrintf("bad service name length (%zd)", |
| 149 | service.size()); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 150 | return -1; |
| 151 | } |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 152 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 153 | int fd; |
| 154 | if (__adb_server_name) { |
Matt Gumbel | d7b3308 | 2012-11-14 10:16:17 -0800 | [diff] [blame] | 155 | fd = socket_network_client(__adb_server_name, __adb_server_port, SOCK_STREAM); |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 156 | } else { |
Matt Gumbel | d7b3308 | 2012-11-14 10:16:17 -0800 | [diff] [blame] | 157 | fd = socket_loopback_client(__adb_server_port, SOCK_STREAM); |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 158 | } |
| 159 | if (fd < 0) { |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 160 | *error = perror_str("cannot connect to daemon"); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 161 | return -2; |
| 162 | } |
| 163 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 164 | if (memcmp(&service[0],"host",4) != 0 && switch_socket_transport(fd, error)) { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 165 | return -1; |
| 166 | } |
| 167 | |
Elliott Hughes | e67f1f8 | 2015-04-30 17:32:03 -0700 | [diff] [blame] | 168 | if(!SendProtocolString(fd, service)) { |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 169 | *error = perror_str("write failure during connection"); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 170 | adb_close(fd); |
| 171 | return -1; |
| 172 | } |
| 173 | |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 174 | if (!adb_status(fd, error)) { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 175 | adb_close(fd); |
| 176 | return -1; |
| 177 | } |
| 178 | |
JP Abgrall | 408fa57 | 2011-03-16 15:57:42 -0700 | [diff] [blame] | 179 | D("_adb_connect: return fd %d\n", fd); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 180 | return fd; |
| 181 | } |
| 182 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 183 | int adb_connect(const std::string& service, std::string* error) { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 184 | // first query the adb server's version |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 185 | int fd = _adb_connect("host:version", error); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 186 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 187 | D("adb_connect: service %s\n", service.c_str()); |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 188 | if (fd == -2 && __adb_server_name) { |
Matt Gumbel | d7b3308 | 2012-11-14 10:16:17 -0800 | [diff] [blame] | 189 | fprintf(stderr,"** Cannot start server on remote host\n"); |
| 190 | return fd; |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 191 | } else if (fd == -2) { |
Stefan Hilzinger | d0eacb8 | 2010-04-19 12:21:12 +0100 | [diff] [blame] | 192 | fprintf(stdout,"* daemon not running. starting it now on port %d *\n", |
| 193 | __adb_server_port); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 194 | start_server: |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 195 | if (launch_server(__adb_server_port)) { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 196 | fprintf(stderr,"* failed to start daemon *\n"); |
| 197 | return -1; |
| 198 | } else { |
| 199 | fprintf(stdout,"* daemon started successfully *\n"); |
| 200 | } |
| 201 | /* give the server some time to start properly and detect devices */ |
Xavier Ducrohet | a481d09 | 2009-05-21 17:47:43 -0700 | [diff] [blame] | 202 | adb_sleep_ms(3000); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 203 | // fall through to _adb_connect |
| 204 | } else { |
| 205 | // if server was running, check its version to make sure it is not out of date |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 206 | int version = ADB_SERVER_VERSION - 1; |
| 207 | |
| 208 | // if we have a file descriptor, then parse version result |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 209 | if (fd >= 0) { |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 210 | std::string version_string; |
| 211 | if (!ReadProtocolString(fd, &version_string, error)) { |
| 212 | goto error; |
| 213 | } |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 214 | |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 215 | adb_close(fd); |
| 216 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 217 | if (sscanf(&version_string[0], "%04x", &version) != 1) { |
| 218 | goto error; |
| 219 | } |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 220 | } else { |
| 221 | // if fd is -1, then check for "unknown host service", |
| 222 | // which would indicate a version of adb that does not support the version command |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 223 | if (*error == "unknown host service") { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 224 | return fd; |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 225 | } |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 226 | } |
| 227 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 228 | if (version != ADB_SERVER_VERSION) { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 229 | printf("adb server is out of date. killing...\n"); |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 230 | fd = _adb_connect("host:kill", error); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 231 | adb_close(fd); |
| 232 | |
| 233 | /* XXX can we better detect its death? */ |
| 234 | adb_sleep_ms(2000); |
| 235 | goto start_server; |
| 236 | } |
| 237 | } |
| 238 | |
| 239 | // if the command is start-server, we are done. |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 240 | if (service == "host:start-server") { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 241 | return 0; |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 242 | } |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 243 | |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 244 | fd = _adb_connect(service, error); |
| 245 | if (fd == -1) { |
| 246 | D("_adb_connect error: %s", error->c_str()); |
Brian Carlstrom | 93c91fa | 2013-10-18 13:58:48 -0700 | [diff] [blame] | 247 | } else if(fd == -2) { |
Matt Gumbel | d7b3308 | 2012-11-14 10:16:17 -0800 | [diff] [blame] | 248 | fprintf(stderr,"** daemon still not running\n"); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 249 | } |
JP Abgrall | 408fa57 | 2011-03-16 15:57:42 -0700 | [diff] [blame] | 250 | D("adb_connect: return fd %d\n", fd); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 251 | |
| 252 | return fd; |
| 253 | error: |
| 254 | adb_close(fd); |
| 255 | return -1; |
| 256 | } |
| 257 | |
| 258 | |
Elliott Hughes | 424af02 | 2015-05-29 17:55:19 -0700 | [diff] [blame] | 259 | bool adb_command(const std::string& service) { |
| 260 | std::string error; |
| 261 | int fd = adb_connect(service, &error); |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 262 | if (fd < 0) { |
Elliott Hughes | 424af02 | 2015-05-29 17:55:19 -0700 | [diff] [blame] | 263 | fprintf(stderr, "error: %s\n", error.c_str()); |
| 264 | return false; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 265 | } |
| 266 | |
Elliott Hughes | 424af02 | 2015-05-29 17:55:19 -0700 | [diff] [blame] | 267 | if (!adb_status(fd, &error)) { |
| 268 | fprintf(stderr, "error: %s\n", error.c_str()); |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 269 | adb_close(fd); |
Elliott Hughes | 424af02 | 2015-05-29 17:55:19 -0700 | [diff] [blame] | 270 | return false; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 271 | } |
| 272 | |
Elliott Hughes | 424af02 | 2015-05-29 17:55:19 -0700 | [diff] [blame] | 273 | return true; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 274 | } |
| 275 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 276 | bool adb_query(const std::string& service, std::string* result, std::string* error) { |
| 277 | D("adb_query: %s\n", service.c_str()); |
Elliott Hughes | 078f0fc | 2015-04-29 08:35:59 -0700 | [diff] [blame] | 278 | int fd = adb_connect(service, error); |
| 279 | if (fd < 0) { |
Elliott Hughes | 3d5f60d | 2015-07-18 12:21:30 -0700 | [diff] [blame^] | 280 | return false; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 281 | } |
| 282 | |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 283 | result->clear(); |
| 284 | if (!ReadProtocolString(fd, result, error)) { |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 285 | adb_close(fd); |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 286 | return false; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 287 | } |
Elliott Hughes | 6452a89 | 2015-04-29 12:28:13 -0700 | [diff] [blame] | 288 | return true; |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 289 | } |