CRC.update_crc C# (CSharp) Method

update_crc() private static method

private static update_crc ( ulong crc, byte buf, int len ) : ulong
crc ulong
buf byte
len int
return ulong
    private static ulong update_crc(ulong crc, byte[] buf, int len)
    {
        ulong c = crc;
        int n;

        if (!s_crc_table_computed)
            make_crc_table();
        for (n = 0; n < len; n++)
        {
            c = s_crc_table[(c ^ buf[n]) & 0xff] ^ (c >> 8);
        }
        return c;
    }