View Single Post
Old 02-03-2010, 07:54 PM   #22
luite
Connoisseur
luite has a complete set of Star Wars action figures.luite has a complete set of Star Wars action figures.luite has a complete set of Star Wars action figures.
 
Posts: 82
Karma: 256
Join Date: Feb 2010
Location: Netherlands
Device: dr1000
Quote:
Originally Posted by owl123 View Post
I'm not into debugging or programming at all but maybe the mobipocket plugin is queried because both ebook formats supported natively by UDS (.mobi and .pdf) work with mobipocket dictionaries.

Maybe the mobipocket plugin returns "The book is corrupted error" because the dictionary function can't recognize the djvu format.
It seems to be extension dependent. If I remove libuds-plugin-pdf.so (the default PDF plugin) and rename my plugin to libuds-plugin-pdf.so and then open a renamed DjVu file (with .pdf extension), it will load just fine. Even when the mobipocket plugin is installed! It does not even ask the plugin whether the file format is supported.

I did some digging around in the uds executable (source code not available, unfortunately), and it seems to have a hardcoded map of extensions and plugins ( uds::PluginMgr::initialize_ext_table ).

The method uds::PluginMgr::create_document first calls uds::PluginMgr::get_plugin_path to check this map for one of the hardcoded extensions. Unknown extensions are handled by loading all plugins and checking them to see if the format is supported.

There may be something that goes wrong there.
luite is offline   Reply With Quote