[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

C++ Bindings Tweak


Hi,

I really like the C++ bindings for LibSSH but it's a little unfortunate that the acceptForward function is defined externally to the class definition, this causes linking errors when the LibSSH C++ header file is included in multiple C++ source files.

I've tweaked the C++ bindings slightly so this problem is eliminated. The only significant changes to the API are the constructors for the Channel and SshException classes. I would argue that these changes are inconsequential because the Channel objects are generated via the Session class, so there's little impact on end users. In addition, the SshException constructor is populated via a preprocessor def which again, has little impact on end users.

Of course, it's probable that I'm not anticipated all angles with these changes so I'd appreciate feedback, the modified C++ header file is attached.

Best Regards
 - Gearoid

Attachment: libsshpp.hpp.bz2
Description: application/bzip


Follow-Ups:
Re: C++ Bindings TweakAndreas Schneider <asn@xxxxxxxxxxxxxx>
Archive administrator: postmaster@lists.cynapses.org