My understanding is that the Geany API has been made safe (I'm not sure if 
sometimes it might result in an additional byte as well as the nul, but that is 
safe).  Not sure about G-P.

I like the idea of making a big message about updating plugins, and we can do 
an audit of G-P fairly simply, so broken plugins can be excluded or fixed by 
interested parties, ie you want your plugin back fix it or persuade somebody to 
do it for you.

The change to Scintilla should have been the other way to be safe, even if 
unchanged code might get an extra byte used (quelle horreur), and its 
unfortunate that Neil didn't take that route.  Sadly I think the chance of 
reverting Scintillas unsafe changes has flown, other users will have adapted.

There are only a few Scintilla messages that are a problem, maybe 
`ScintillaGTK.cxx` scintilla_send_message() can be patched to check for the bad 
message numbers and silently increment the count safely, we already patch that 
file to add GEANY_API_SYMBOL to scintilla_send_message(), a slightly bigger 
patch won't hurt.  And remember bad plugins crash Geany, a few bytes don't 
matter.

> Well, for one thing, it won't really scale (lots of APIs, new APIs, etc.). 

Yes, but I bet there is a lot of duplication, so _most_ of the direct SSM calls 
can be removed with only a few extra wrappers.  That reduces the surface area 
for problems.  Anyway I prevaricated sufficiently by saying "over time" etc etc 
to allow flexibility.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/3095#issuecomment-1436968355
You are receiving this because you are subscribed to this thread.

Message ID: <geany/geany/issues/3095/[email protected]>

Reply via email to