馃懡 reinboar

I鈥檝e decided to do something crazy and write my own Gemini server implementation. I鈥檝e written my own Gopher server in Chicken Scheme before but I鈥檓 going to attempt this one in C++, so this may be the last you see of my sanity.

1 year ago 路 馃憤 shway, know, negepezzannyitfiam

Actions

馃憢 Join Station

12 Replies

馃懡 martin

@skyjake 馃檶 路 1 year ago

馃懡 aka_dude

@reinboar >not a programmer by trade

Oh boy. Than I hope you are ready to become C guru, because otherwise you'll have trouble with UB (and I'm positive about that) 路 1 year ago

馃懡 aka_dude

@skyjake thank you! 路 1 year ago

馃懡 reinboar

@aka_dude I definitely don鈥檛 think that C/C++ can鈥檛 or shouldn鈥檛 be replaced with something like Rust, but in terms of platforms, there is more available to me with C/C++. For example, unless something has changed, the DS and GBA are both pretty much exclusively developed for with C/C++ which makes it particularly interesting for me. Also, I鈥檓 not a programmer by trade so I鈥檓 not personally too concerned with language choice outside of what strikes me as interesting or useful for my very specific goals. 路 1 year ago

馃懡 skyjake

@aka_dude It is fixed for 1.8.2. Interestingly, the input validator length indicator was already counting + as 3 bytes although it wasn't sent as such.

@martin Apologies, I was kind of assuming this was a problem on your end and didn't double-check my own code...! 路 1 year ago

馃懡 skyjake

@aka_dude I checked the specs. Plus is among the reserved URL characters in RFC3986, and that's what the Gemini specification says should be applied. Therefore, it is indeed a bug in Lagrange and I'll fix it.

Of course, Gemini query strings don't use subcomponents, so escaping them is pointless beyond compatibility with existing URL parsers. Some capsules like geminispace.info works fine without encoded plusses. 路 1 year ago

馃懡 aka_dude

@skyjake Lagrange eats my pluses :( 路 1 year ago

馃懡 aka_dude

Why C ? Don't you think that by learning it you prolong its life / or do you find it OK language, no need for replacement? 路 1 year ago

馃懡 shway

using Threads, non-blocking, pre-forking or forking? A combo? 路 1 year ago

馃懡 marmaladefoo

As with most modern software it comes down to whether you have some sensible libraries to build on. Write your own network stack? Write your own UI layer? Write your own cross-platform implementation? Eeek. 路 1 year ago

馃懡 reinboar

@marginalia Especially since I鈥檓 using this as an exercise to learn C++, we鈥檒l see how far I get haha. I鈥檝e got a healthy amount of experience with multithreaded applications in other languages though so hopefully that will carry over here. 路 1 year ago

馃懡 marginalia

Good luck. Gemini servers are surprisingly straight forward to set up, although C is perhaps not the easiest language to do it in. But nothing impressive ever got done only chasing what's easy. 路 1 year ago