Commit a111601d7342847875ffb25dccd328fe946255b2
- Diff rendering mode:
- inline
- side by side
emulator/qtools/dmtrace.cpp
(2 / 2)
|   | |||
| 163 | 163 | // sig = "()I" | |
| 164 | 164 | ||
| 165 | 165 | // Find the first parenthesis, the start of the signature. | |
| 166 | char *paren = strchr(name, '('); | ||
| 166 | char *paren = (char *) strchr(name, '('); | ||
| 167 | 167 | ||
| 168 | 168 | // If not found, then add the original name. | |
| 169 | 169 | if (paren == NULL) { | |
| … | … | ||
| 180 | 180 | *paren = 0; | |
| 181 | 181 | ||
| 182 | 182 | // Search for the last period, the start of the method name | |
| 183 | char *dot = strrchr(name, '.'); | ||
| 183 | char *dot = (char *) strrchr(name, '.'); | ||
| 184 | 184 | ||
| 185 | 185 | // If not found, then add the original name. | |
| 186 | 186 | if (dot == NULL || dot == name) { |
|   | |||
| 1009 | 1009 | // be freed by the caller after it is no longer needed. | |
| 1010 | 1010 | static char *ExtractDexPathFromMmap(const char *mmap_path) | |
| 1011 | 1011 | { | |
| 1012 | char *end = rindex(mmap_path, '@'); | ||
| 1012 | const char *end = rindex(mmap_path, '@'); | ||
| 1013 | 1013 | if (end == NULL) | |
| 1014 | 1014 | return NULL; | |
| 1015 | char *start = rindex(mmap_path, '/'); | ||
| 1015 | const char *start = rindex(mmap_path, '/'); | ||
| 1016 | 1016 | if (start == NULL) | |
| 1017 | 1017 | return NULL; | |
| 1018 | 1018 | int len = end - start; |

