Esempio n. 1
0
        static void ParseErrors(PeVerifyResult result, string stdOut)
        {
            result.Errors = new List <string>();

            int startIndex = 0;

            while (startIndex < stdOut.Length)
            {
                startIndex = stdOut.IndexOf("[IL]:", startIndex);
                if (startIndex == -1)
                {
                    break;
                }

                int endIndex = stdOut.IndexOf("[IL]:", startIndex + 1);
                if (endIndex == -1)
                {
                    // Look for the last line...
                    endIndex = stdOut.IndexOf("\r\n", startIndex + 1);
                }

                result.Errors.Add(result.NormalizeErrorString(stdOut.Substring(startIndex, endIndex - startIndex)));
                startIndex = endIndex;
            }
        }
Esempio n. 2
0
        static void ParseErrors(PeVerifyResult result, string stdOut)
        {
            result.Errors = new List<string>();

            int startIndex = 0;
            while (startIndex < stdOut.Length)
            {
                startIndex = stdOut.IndexOf("[IL]:", startIndex);
                if (startIndex == -1) break;

                int endIndex = stdOut.IndexOf("[IL]:", startIndex + 1);
                if (endIndex == -1)
                {
                    // Look for the last line...
                    endIndex = stdOut.IndexOf("\r\n", startIndex + 1);
                }

                result.Errors.Add(result.NormalizeErrorString(stdOut.Substring(startIndex, endIndex - startIndex)));
                startIndex = endIndex;
            }
        }