System.TermInfo.Database.FindNullTerminator C# (CSharp) Méthode

FindNullTerminator() private static méthode

Finds the null-terminator for a string that begins at the specified position.
private static FindNullTerminator ( byte buffer, int pos ) : int
buffer byte
pos int
Résultat int
            private static int FindNullTerminator(byte[] buffer, int pos)
            {
                int termPos = pos;
                while (termPos < buffer.Length && buffer[termPos] != '\0') termPos++;
                return termPos;
            }
        }