Skip to content Skip to sidebar Skip to footer

Npapi Plugin Debugging

What is the best practice to debug a npapi plugin. I am currently developing a plugin with the help of nixysa. I currently debugging printing intermediate values to log file. Is th

Solution 1:

Well, I could start out by implying that the first better way is to use FireBreath instead of nixysa, but that would be rude and might give away my bias ;-) Seriously, though, there is nothing wrong with nixysa; I recommend FireBreath simply on the merit that it works on IE as well on windows and has a lot more bugfixes and workarounds to make sure everything works on all browsers and platforms.

There are a lot of suggestions for debugging plugins in general (as in attaching debuggers to them) on the FireBreath wiki that all pretty well apply to any NPAPI plugin.

Getting debugging methods like that working on linux can be particularly a pain, so on linux I usually lean more towards using a logging framework such as log4cplus.

Others may have more suggestions, but it would probably help if we knew exactly which platforms you were targetting; for example, Chrome (I notice that tag on the question) supports a --plugin-startup-dialog option that is invaluable for attaching to the plugin before it starts up due to the multi-process nature of plugins on Chrome. IE and Firefox both have options to disable OOP (out of process) plugins, which makes attaching to them easier.


Post a Comment for "Npapi Plugin Debugging"