Known Bugs

| # # Known Bugs

``

`
`

``Here follows the description and status of old bugs. For recent bugs please consult the bug tracker on sourceforge. ```` `` `#1:` `` `description: files pointed to by a symbolic links get their times (mtime & atime) not properly restored` `` `` `` `problem: when restoring time of a symbolic link the utime() system call does not change the inode of the symbolic link itself but the one of the file pointed to by the symbolic link` `` `` `` `solution: as the utime() call behaves the same on many Unix platforms, (HP-UX, Solaris, Linux, etc.), the times for the symbolic links are` `no more restored, thus files pointed to by symbolic links are not` `affected by the utime() strange behavior. Dar, behaves not the` `same as touch, tar, etc.` `` `` `` `affects version: 1.0.0` `` `fixed in version: 1.0.1` `` `` `` `#2:` `` `description: dar immediately exits with message "file mode is neither read nor write" while creating an archive on 64 bits platforms.` `` `` `` `problem: missing mask with O_ACCMODE for flags returned by fcntl()` `system call` `` `solution: O_ACCMODE mask added` `` `affects versions: 1.0.0, 1.0.1` `fixed in version: 1.0.2` `` `` `` `#3:` `` `description: making differential backup with some directory implicitly or` `explicitly (-P) excluded, sometime lead to full backup.` `` `problem: when entering a directory that was ignored, the comparison in the` `catalogue of reference was not going back to the parent directory,` `leading the comparison to be no more synchronized with the file being` `read.` `` `solution: added a line to go back to parent directory when treating an` `ignored directory` `` `affects versions: 1.0.0, 1.0.1` `fixed in version: 1.0.2` `` `` `` `#4:` `` `description: on Linux 64 bits, when an interaction from the user is` `required, (escape or return key), the keys have to be pressed four` `time before dar can read a character.` `` `problem:` `unknown, same code works fine on other platforms, and if bad character` `remains in the pipe, the message would be displayed several time,` `which is not the case, here. It seems that the user has to press four` `key for the first one to be accessible to dar.` `` `solution: none actually` `` `affects versions: 1.0.0, 1.0.1 , 1.0.2 and probably also 1.1.0` `fixed in version: none` `` `` `#5:` `` `description: Dar stops one of the two following error:` `--- exception nature = [alive] exception type = [BUG] ----------` `[source]` `file compressor.cpp line 244 : it seems to be a bug here` `[most outside call]` `-----------------------------------` `` `or` `` `--- exception nature = [alive] exception type = [BUG] ----------` `[source]` `file compressor.cpp line 254 : it seems to be a bug here` `[most outside call]` `-----------------------------------` `` `problem:` `the zlib deflate() calls returned an unexpected value (Z_STREAM_END)` `and inflate() in some rare cases was called without data to process,` `when reaching end of file, which made inflate() to return Z_BUF_ERROR` `code.` `` `solution:` `adding code for taking care of the returned code Z_STREAM_END by` `deflate(), and code for taking care of Z_BUF_ERROR returned at end` `of file.` `` `affects version: 1.0.0, 1.0.1, 1.0.2` `fixed in version: 1.0.3` `` `` `` `#6:` `` `description: Dar does not properly display dates on Linux 64 bits` `systems.` `` `problem:` `non portable cast from 'time_t' to 'unsigned long int'` `` `solution:` `changed code not to have to use 'unsigned long int'` `` `affects version: 1.0.x, 1.1.x` `fixed in version: 1.2.0` `` `` `` `#7:` `` `description: while saving, Dar stops when a given inode could not be read,` `even if the inode had not to be saved` `` `problem:` `Dar reads all file in the directory to save, and then applies filters` `to their filename. Error appears before the filter, leading to a` `global saving error.` `` `solution:` `read error are now caught sooner a message is displayed that the file` `or directory will be ignored, and saving process continues. As` `this error occurs before testing filename against filters, an error` `message is still displayed (which may seems strange when the file was` `about to be excluded by filter mechanism)` `` `Just reminds that dar reads a directory contents first, and` `then check filenames against filter. At the time of the message, Dar` `does not know the file would not to be saved. Thus, don't worry if` `you see this kind of message, they don't mean that dar was about to` `save the given file but rather exactly what the message says, that` `the file or directory could not be read. ;-)` `` `affects version: 1.0.x, 1.1.x` `fixed in version: 1.2.0` `` `` `` `#8:` `` `description: when saving hard linked file using filter that does not save` `the first hard link, dar stops with SEGFAULT.` `` `problem:` `The first hard link is used as reference for the following occurrences.` `As it is not covered by the filter it is destroyed in filter module,` `but filesystem module keeps using it as reference for following` `hard links on that inode.` `` `solution:` `added a call in filesystem module to "forget" a given reference. This` `way, if a file_etiquette is not covered, filter module can inform` `filesystem module to delete the corresponding entry on the hard link` `map. Subsequent hard link on that inode will generate first a new` `file_etiquette, which will be used as reference (unless it is not` `covered by filter too).` `` `affects version: 1.1.x` `fixed in version: 1.2.0` `` `` `` `#9:` `` `description:` `failed to read an archive under windows NT and 2000` `` `problem:` `error concerning the integer macro definition (module integer.hpp)` `` `solution:` `replaced the macro by a proper definition.``` `` `affects version: 1.2.0` `fixed in version: 1.2.1` `` `` `#10:` `` `description:` `when using dar on windows95 if giving c:/ or other driver to -R` `option, dar stops with the following error:` `` `file filesystem.cpp line 186 : it seems to be a bug here` `` `problem:` `dar checks first that c:/ is a directory. Cygwin says yes this` `dar continues : from c:/ dar completes the path with a dot thus` `dar tries to open the path c:/. which is Cygwin does not report` `as an existing directory.` `` `solution:` `dar does not try to open c:/. but tries to open c:/ . Moreover` `additional code as been added to detect the incoherence if in` `some other conditions such problem occurs. Dar will report the` `exact problem (path does not exist / or path is not a directory)` `` `affects version: 1.2.1, 1.2.0` `fixed in version: 1.3.0` `` `` `#11:` `` `description: when giving to dar_manager an absolute path to -r option dar_manager stops with INTERNAL ERROR message.` `` `problem: a check is missing to display error message in such condition` `` `solution: added a error message, if an absolute path is given to -r` `` `affects dar_manager version : 1.0.0` `fixed in dar_manager version : 1.0.1` `` `` `#12:` `` `description: memory leakage when using -Z or -Y option. This bug has been found and explained by David Rose, who proposed a good patch, which I have just a little adapted.` `` `problem: the dar code that call the zlib when changing the compression algorithm did properly released memory allocated by dar but forget to execute a call of the zlib library that releases memory allocate by the library itself.` `` `solution: solution, add call to release memory used by zlib library when changing of compression algorithm` `` `affects dar version : 1.2.0, 1.2.1` `fixed in dar version : 1.3.0` `` `` `#13:` `` `description: archive created by dar under Windows NP SP6, XP, 2000, cannot be read, tested. All action on generated archive finishes by CRC error message, incoherent catalogue structure, or badly formated infinint.` `` `problem: under windows, Dar uses Cygwin. As Unix and Window do not define end of line the same way (\n for Unix and \r\n for Windows), Cygwin translates end of line on the fly when reading a file (Windows to Unix), and when writing (Unix to Windows). At writing time especially, each \n anywhere in the archive is written \r\n, thus two bytes get written in place of one. In another hand, to get the global position in the whole archive dar counts bytes it writes to file. Thus a shift occurs between the position it thinks it writes the catalogue and the position it actually does. Thus reading the archive, the given position is wrong, and archive cannot be opened.` `` `solution: deactivate the translation when generating the archive. Cygwin adds a two special flags to pass to open(2) which are O_TEXT and O_BINARY, that change the way Cygwin handles file read(2) and write(2).` `` `affects all dar suite program version 1.0.x, 1.1.x, 1.2.x` `fixed in dar version 1.3.0` `` `` `#14:` `` `description: Dar aborts with the following message` `` `---- exception nature = [alive] exception type = [BUG] ----------` `[source]` `file compressor.cpp line 320 : it seems to be a bug here` `[most outside call]` `-----------------------------------` `` `It appears while doing a backup using compression and scrambling (could not (yet) be reproduced twice).` `` `problem: this message is issued because zlib library reported an inconsistency in call order or in call arguments given to zlib calls. Actually I cannot figure out what is wrong, nor how this bug may happens.` `` `solution: none actually at the time of 2.0.0 release.` `` `But, if you are face to face with this bug, thanks to try reproducing it, re-issuing the same command in the same condition, and if possible to reproduce then as much as possible reduce the necessary environment condition that make this bug happen. Then please, contact me (either via Sourceforge or via email).` `` `affects version 1.2.1 (at least)` `not yet fixed (check Sourceforge for fresh news), nor reproduced.` `` `` `#15:` `` `description: Dar aborts with the following message when giving -y0 as argument` `` `---- exception nature = [alive] exception type = [BUG] ----------` `[source]` `file compressor.cpp line 96 : it seems to be a bug here` `[most outside call]` `-----------------------------------` `` `problem: correct compression level for zlib are from 0 to 9, 0 meaning no compression, while for libbz2 correct compression levels are from 1 to 9, thus zero is not a valid value. libbz2 returns an error code which triggers a libdar internal sanity check code, which throws this BUG exception.` `` `` `solution: forbid the use of -z0 or -y0. If you don't want compression, you will need to not give neither -z nor -y.` `` `affects version 1.3.0` `fixed in version 2.0.0` `` `` `#16:` `` `description: Dar include does not ignore comments in included file as given by -B option` `` `problem: when a line with only one carriage-return is put in a file, the following line is considered as a normal line (not a comment), whatever it is, in particular if it starts with a hash (#).` `` `solution: make the algorithm consider normal line once another character than space, tab hash or carriage-return is met. (added the carriage-return in the list).` `` `affects version 1.2.0, 1.2.1, 1.3.0` `fixed in version 2.0.0` `` `` `` `#17:` `` `description: Dar warns that the archive is about to save itself while a -P option is used to prevent this eventuality.` `` `problem: testing against this situation did not check that a parent directory of the path where is saved the archive is excluded by a -P option.` `` `solution: updating the test for the warning only appear in real auto-saving conditions.` `` `affects version 2.0.0` `fixed in version 2.0.1` `` `` `#17bis:` `` `description: save as #17, but in the case where the archive is in the under the current directory, and some -P options exclude it.` `` `problem: the current directory "." is not substitued by its full path, and the testing algorithm does tread "." as directly under the root "/" directory, no -P could thus exclude it from the files to save.` `` `solution: for testing and preventing self-backup, "." is replaced by its full path counterpart. affects version 2.0.0, 2.0.1, fixed in version 2.0.2` `` `` `#18:` `` `description: Dar does not save files or just stores empty directories when using -B option or having a ~/.darrc or /etc/darrc file` `` `problem: the parsing code that strip the comments from files is not counting empty lines ('\n') between two lines of commands (i.e.: uncommented lines). This strips the last uncommented line before the next line of comment, usually leading to the removal of an ending '\n' in the uncommented line, implying the fusion of the last command on this line and the next command on any uncommented after the last line of comment two commands that were initially separated by a '\n' and one or several lines of comments. This wrongly interpreted command most of the time appear as a member of [list of path] and thus restricts the backup to only a subdirectory that most of the time does not exist. If -D option is used, all first level directory are excluded from backup and thus stored as empty directories.` `` `solution: bug fix in no_comment.cpp. A workaround is to remove comments or empty lines from configuration files.` `` `affects versions 2.0.0, 2.0.1` `fixed in versions 2.0.2` `` `` `#19:` `` `description: Dar hangs when using --nodump with named pipe to save` `` `problem: to get the nodump flag value, dar needs to call the open() system call in read-only mode. For named pipes this system call does return only when another process opens the same pipe in write mode.` `` `solution: as proposed by Joshua Neal, the open will be set to non blocking mode to return immediately.` `` `affects version 1.3.0, 2.0.0, 2.0.1` `fixed in version 2.0.2` `` `` `#20:` `` `description: dar_manager did not completely removed reference to an archive when it was removed from a database` `` `problem: data_dir is a C++ class that inherit from data_tree. This one has a virtual method remove_all_from(), that had was redefined in the data_dir class with a very little difference, making it not be a redefinition of the inherited class. (argument was "archive_num" in place of "const & archive_num"). This redefined method was never called, and the removal never recursed in subdirectories.` `` `solution: make the two signature identical in the mother and inherited classes.` `` `affects version 1.3.0, 2.0.0, 2.0.1, 2.0.2` `fixed in version 2.0.3` `` `` `#21:` `` `description: under FreeBSD using -B option leads to parse error` `` `problem: under FreeBSD, getopt() call is not reset just by setting optind to zero like under Linux, but the variable optreset must be set to 1.` `` `solution: configure script now check for the presence of optreset variable which allows to properly reset the getopt call according to the system nature.` `` `affects version 2.1.0 and older` `fixed in version 2.1.1` `` `` `#22:` `` `description: dar stops when fed with an empty file for -B option` `` `problem: the comments stripping class lack a variable initialization` `` `solution: initialize variable before use` `` `affects version 2.1.0 and older` `fixed in version 2.1.1` `` `` `` `#23:` `` `description: -z -y -H and -w do not work under FreeBSD` `` `problem: the getopt() version does not support optional arguments` `` `solution: document this problem, and make possible to reach any feature` `` `in the meanwhile, replace` `-z by -z 9` `-y by -y 9` `-H by -H 1` `-w by -w d (added for the circumstances)` `` `affects all versions` `documented starting version 2.1.2 (see dar's man page)` `` `` `#24:` `` `description: under windows 2000 SP4 failed to properly save a text file with DOS carriage return. Testing the archive reports CRC error.` `` `problem: The cygwin adaptation layer for dar to be able to run under windows, needs non standard flag mode to not automatically translate between windows and unix carriage return. This bug is related to bug #13 which fix was not properly applied in one single place.` `` `solution: properly apply the fix of bug #13 in this single place too.` `` `affects version 2.1.1 and older` `fixed in version 2.1.2` `` `` `#25:` `` `description: under some hypothetical conditions (when the archive is larger than 10^16 Terabytes, 1 followed by 16 zeros), dar is not able to read the archive.` `` `problem: In this situation, the terminateur is not properly formed and cannot fulfill its role: point to the start of the catalogue. A byte 0x00 is missing near the end of the archive, that indicate the end of the terminateur.` `` `solution: properly write down terminateur string of archive. Note that archive produced by earlier version are not possible to read dar version that have the fix, but don't worry, if you have a such big archive (more than 10^16 Terabytes), tell me I will create a little program that fixes the archive ;-) . Note, "terminateur" the french word for terminator, the word has been kept here because it is used in the source code.` `` `affects version 2.1.2 and older` `fixed in version 2.1.3` `` `` `#26:` `` `description: in configuration file using conditional syntax (see man page), when two targets follow each other on two directly following lines (the first condition is thus empty), the second condition is skipped. This condition also occurs if there is only comments between the two targets.` `` `problem: when looking for the first target, an extra character is read (the first of the second target), as there is no contents in this target no reposition (seek) in the file is done, and the search for the next target start at that point (second character of the second target), which makes the second target not recognized because of the missing initial character.` `` `solution: avoid reading this extra character so the next character to read is the first character (not the second) of the following target.` `` `affects version 1.2.0 and older versions` `fixed in version 2.1.3` `` `` `` `#27:` `` `description: when restoring only more recent files (-r), with hourshift activated (-H) the -H feature was randomly not activated.` `` `problem: a test comparing the dates is made on address's objects rather on objects themselves. This leads to the -H test being activated randomly depending on address of two objects to compare.` `` `solution: make the test on objects rather than on their addresses in memory.` `` `affects version from 2.0.0 to 2.1.3` `fixed in version 2.1.4` `` `` `#28:` `` `description: dar does not restore root Extended Attributes` `` `problem: a collision occurred in the naming of the enumeration listing the extended attributes available domains, and the variables carrying user choice to consider or not user or root extended attributes for the operation (backup, restoration, comparison, etc.)` `` `solution: rename both the domain enumeration and the variables carrying user choice about extended attribute comportment.` `` `affects version from 2.1.0 to 2.1.3` `fixed in version 2.1.4` `` `` `#29:` `` `description: dar does Segmentation fault during backup when hard links are involved` `` `problem: when an plain file inode linked several time to the directory tree (a hard linked file), is not readable due to a lack a permission, the filesystem module generates a C++ object and stores its address for further reference and hard link handling. When the file opening comes an exception is throw, leading to this object destruction, but the reference stays in the the filesystem module, leading the next link to this inode being referenced by a destroyed object.` `` `solution: remove the reference when exception is caught. This removal was properly done when such an inode was not to be saved (and the corresponding C++ object was destroyed), the case of the exception had been forgotten.` `` `affects version up to 2.1.4` `fixed in version 2.1.5` `` `` `#30:` `` `description: compilation failed with syntax error reported in libstdc++ header files (reported on Solaris and openBSD).` `` `problem: the configure scripts does detect the presence of mbstate_t type, and redefines it. This conflicts the system header files and lead to a syntax error.` `` `workaround 1:` `` `will update the configure script to check if that fixes the problem. Else there is a workaround. Once configure has finished, edit the config.h file adding the line` `#define HAVE_MBSTATE_T 1` `and commenting out the line` `#define mbstate_t int` `Thanks to Steve Evans for this workaround.` `` `` `solution: undefine the mbstate_t in dar's source code. This is implemented and seems to work. No action is required for your part.` `` `may affects version up to 2.2.0` `fixed in version 2.2.1` `` `` `` `#31:` `` `description: dar segfault when restoring Extended Attributes` `` `problem: to speed up the reading of the catalogue from an archive an intermediate layer has been added thanks to an "cache" object. This object is temporary instead of the object it does caching on. When the catalogue reading has finished, the reference given to inode becomes invalid because it is the caching object in place of the real underlying archive object.` `` `solution: keep doing archive reading through the caching object but give the real archive object to the inode contained in the catalogue for they have a valid reference when it is time to restore EA.` `` `affects version 2.2.0` `fixed in version 2.2.1` `` `` `#32:` `` `description: dar is unable to read blowfish encrypted archives under certain conditions` `` `problem: this bug appears when using infinint (no --enable-mode in command-line). The implicit cast from a unsigned integer to an infinint in a operation was not properly made by the compiler. Instead of converting the system integer to an infinint which is possible thanks to the infinint constructor class, the compiler down cast the the unsigned integer to unsigned char.` `` `solution: use explicit cast conversion when doing operations which concern both infinint and unsigned integers.` `` `affects version 2.2.0` `fixed in version 2.2.1` `` `` `#33:` `` `decription: dar hangs when the last line of a DCF file is starting with a few spaces or tabs just following a comment.` `` `problem: The layer that removes comments was counting the bytes from the beginning while the first byte retained as significative was the first non space of the line. leading to provide to upper layer a wrong information about the number of byte in the file.` `` `solution: start counting bytes from the first significative byte of the line instead of the first byte of the line.` `` `affects versions 2.1.x up to 2.2.0` `fixed in version 2.2.1` `` `` `#34:` `` `description: when restoring files in a directory, this one has all permission set for every body. This makes a security hole on multi-user system.` `` `problem: when restoring in a directory as non privileged user it is necessary to have write access to that directory, thus temporary change the permission. The permission is thus changed, but the temporary change is too permissive, thus opens a security hole, allowing local user delete/create/replace under the directory restored.` `` `solution: only add the user write access (if necessary) to the directory when dar is run as non privileged user.` `` `affects versions 1.x.x up to 2.2.0` `fixed in version 2.2.1` `` `` `#35:` `` `description: when producing archive to stdout sometimes the message "Error while saving data: Bad file descriptor given" is displayed and dar aborts its execution` `` `problem: health check done on a uninitialized object field in place of a constructor's argument that will be used to set this field.` `` `solution: test the method's argument in place of the object field` `` `affects version 2.2.x up to 2.2.3` `fixed in version 2.2.4` `#36:` `description: when using -I or -X with -l option directory names are also filtered while they should not be, as described in the man page` `` `solution: avoid having -X/-I filtering directories` `` `affected versions 2.2.x up to 2.2.5` `fixed in 2.2.6` `#37:` `description: when restoring a file which all EA has been dropped since the archive of reference, dar reports CRC error.` `` `problem: to store that EA has been dropped, dar saves an empty EA list, but did not calculated the CRC value` `` `solution: make the CRC value set when storing an empty list of EA. Note that this bug did not cause any problem except a CRC error message.` `` `affects versions up to 2.2.6` `fixed in 2.2.7`