| 1904 | |
| 1905 | |
| 1906 | static std::string CheckForASCIIString(const DataBuffer& memory) |
| 1907 | { |
| 1908 | std::string result; |
| 1909 | size_t i = 0; |
| 1910 | while (true) |
| 1911 | { |
| 1912 | if (i > memory.GetLength() - 1) |
| 1913 | break; |
| 1914 | if (IsPrintableChar(memory[i])) |
| 1915 | { |
| 1916 | result += memory[i]; |
| 1917 | i++; |
| 1918 | } |
| 1919 | else |
| 1920 | { |
| 1921 | break; |
| 1922 | } |
| 1923 | } |
| 1924 | |
| 1925 | if (result.length() >= 4) |
| 1926 | return result; |
| 1927 | else |
| 1928 | return ""; |
| 1929 | } |
| 1930 | |
| 1931 | |
| 1932 | static std::string CheckForUTF16String(const DataBuffer& memory) |
no test coverage detected