anchor.diff:  
       (string-right-trim '(#\Space) name)))
   
  -(defun (setf read-short-name) (short-name directory offset)
  -  (loop :for i :from offset :to (+ 10 offset)
  -        :for char :across short-name
  -        :do (setf (aref directory i) (char-code char))))
  -
  -(defmacro do-file ((var start) directory finally &body body)
  -  (alexandria:with-gensyms (checksum order order1)
  -    `(do ((,checksum (checksum ,directory ,start))
  -          (,order -1 (1+ ,order))
  -          (,order1 0 (aref ,directory ,var))
  -          (,var ,start (- ,var 32)))
  -         ((or (> 0 ,var)
  -              (= (+ #x40 ,order)
  -                 ,order1))
  -          ,finally)
  -       (when (= ,checksum
  -                (aref ,directory (+ 13 ,var)))
  -         ,@body))))
  -
   (defun read-long-name-section (directory offset)
     (let ((name (make-string 13 :initial-element #\Space))
           (idx 0))
  
positive.code:       (when (string= short-name (read-short-name file offset))
          (error "Short name ~A does alredy exist.~A~%Short name collision resolution not implemented" short-name)))))
  
  (defun create-file (host file cluster-n pathname-name pathname-type attributes)
    "Create file/directory"
    (multiple-value-bind (time date) (get-fat32-time)
      (let* ((name (concatenate 'string pathname-name "." pathname-type))
             (short-name (make-short-name pathname-name pathname-type file))
             (name-length (length name))
             (start-offset (next-n-spaces file (if (> name-length 11)
                                                   (1+ (ceiling (/ name-length 13)))
                                                   1)))
             (end-offset (+ start-offset (ash (if (> name-length 11)
                                                  (ceiling (/ name-length 13))
                                                  0)
                                              5)))
             (cluster-number (next-free-cluster (fat host) 3)))
        (flet ((set-short-name (name file start-offset cluster-number)
                 (setf (read-short-name file start-offset) name
                       (read-attributes file start-offset) attributes
                       (read-reserved file start-offset) 0
                       (read-creation-time-tenth file start-offset) 0
                       (read-creation-time file start-offset) time
                       (read-creation-date file start-offset) date
                       (read-last-access-date file start-offset) date
                       (read-write-time file start-offset) time
                       (read-write-date file start-offset) date
                       (read-first-cluster file start-offset) cluster-number
                       (read-file-length file start-offset) 0)))
          ;; Write short name part
          (set-short-name short-name file end-offset cluster-number)
          ;; Write long name parts only if needed
          (unless (and (>= 8 (length pathname-name))
                       (>= 3 (length pathname-type)))
            (setf (read-long-name file start-offset) name))
          ;; Make directory files . and ..
          (when (directory-p file end-offset)
            (let ((directory (make-array (bytes-per-cluster (fat-structure host))
                                         :area :wired :element-type '(unsigned-byte 8)
                                         :initial-element 0)))
              (set-short-name ".          " directory 0 cluster-number)
              (set-short-name "..         " directory 32 cluster-n)
              ;; Write to disk
              (write-file (fat-structure host)
                          (partition host)
                          cluster-number
                          (fat host) directory))))
        ;; Write to disk
        (write-file (fat-structure host) (partition host) cluster-n (fat host) file)
        ;; Update fat
        (setf (aref (fat host) cluster-number) (last-cluster-value (fat-structure host)))
        (write-fat (partition host) (fat-structure host) (fat host))
        ;; Return cluster-number
        cluster-number)))
  
  ;;; Host integration
  
  
negative.code:        ;; If this is the last block, exit the loop
         when (logbitp 6 (aref directory offset)) do (return))
      name))
  
  (defun short-name-p (directory file)
    (or (= file 0) ;; first directory entry, can't have long name
  