[AVFS] Segfault using #ulha#utar
Ralf Hoffmann <[email protected]> Thu, 26 Jan 2006 19:37:18 +0100
| Newsgroups | gmane.comp.file-systems.avfs.user |
|---|---|
| Message-ID | <[email protected]> |
Hi, I'm currently hunting down a bug in the archive handler. I noticed a segfault when accessing a file named "t.tar.lha#" which is resolved to "t.tar.lha#ulha#utar". I backtraced the whole virt_open call and came to the following problem: Looking up the "utar" segment leads to the function "parse_tarfile" which opens the base file, in this case the ulha-handled file. Nothing wrong so far. Opening the ulha file leads to arch_do_open. Around line 359 in archive.c in this function a new archfile struct is created. The nod for this struct is the default node for the ulha entry. Especially its data entry is NULL (the struct extfsnode entry). Finally ap->open is called (it's actually extfs_open) and the get_extfs_file function accesses the extfsnode which is NULL. I looked over this problem to find a good solution. "t.tar.lha#ulha" is a directory and open() on directories is allowed. However, since we can't return any handle for an extfs entry without a path I think the only solution is to return an error in get_extfs_file. Returning -EISDIR is perhaps a good choice. What do you think about this? I hope my description of this problem is enough to understand it but if you need more information I have plenty of it :-) Besides this, I'm looking into some other minor problems but I will write about it later :-) Best Regards, Ralf Hoffmann -- Homepage: http://www.boomerangsworld.de E-Mail: Ralf Hoffmann <[email protected]> english or german ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642