protected function readBinaryDate($length)
    {
        if ($length > 3) {
            throw new PListException("Date greater than 8 bytes: $length");
        }

        $nbytes = 1 << $length;
        $val = null;
        if (strlen($buff = substr($this->content, $this->pos, $nbytes)) != $nbytes) {
            throw IOException::readError("");
        }
        $this->pos += $nbytes;

        switch ($length) {
            case 0: // 1 byte CFDate is an error
            case 1: // 2 byte CFDate is an error
                $x = $length + 1;
                throw new PListException("{$x} byte CFdate, error");

            case 2:
                $val = unpack("f", strrev($buff));
                $val = $val[1];
                break;
            case 3:
                $val = unpack("d", strrev($buff));
                $val = $val[1];
                break;
        }

        return new CFDate($val, CFDate::TIMESTAMP_APPLE);
    }