# example loadfile for SMB # # We do not distinguish between different error types so the last parameter, # the status is # SUCCESS that the operation must be successful # ERROR that the operation must fail # * which means don't care # # Filenames in SMB MUST start with '\' or '/' # # # Delete an entire directory tree. #Deltree "/" SUCCESS # # # # MKDIR MKDIR "/foo" SUCCESS # # # RMDIR RMDIR "/foo" SUCCESS RMDIR "/foo" ERROR RMDIR "/foo" * # # # Open/Create # OPEN # Flags are the combination of these flags, ored together # 0x01 O_RDONLY # 0x02 O_WRONLY # 0x04 O_RDWR # # 0x08 O_CREAT create the file if it does nto exist # 0x10 O_EXCL fail if the file already exists # 0x20 O_TRUNC if the file exists, truncate it # 0x40 O_APPEND open in append mode only OPEN "/test.txt" 0x1c SUCCESS # # # # WRITE WRITE "/test.txt" 0 100 SUCCESS WRITE "/test.txt" 0 50 SUCCESS WRITE "/test.txt" 50 50 SUCCESS # # # # READ READ "/test.txt" 0 100 SUCCESS # # # # CLOSE CLOSE "/test.txt" SUCCESS # # # # UNLINK UNLINK "/test.txt" SUCCESS # # # # READDIR READDIR "/" SUCCESS