/// <summary> /// Find a byte array in a buffer. Returns all instances of the compare array. /// </summary> /// <param name="buffer">The buffer to find the data in.</param> /// <param name="compare">The comparison byte array.</param> /// <returns>A list of offsets into the buffer where the compare was found.</returns> public static IEnumerable <int> FindBuffer(this SafeBuffer buffer, byte[] compare) { return(buffer.FindBuffer(0, compare)); }