문제

I'm kind of stuck trying to code an example of file transfer using libpurple.

My first try was to reuse the nullclient example from the libpurple/examples source directory and call serv_send_file. That seems to compile and execute fine but then nothing happens in the side of the receiver (he doesn't get the file transfer request).

Pointers and/or partial code (in any language) are appreciated.

도움이 되었습니까?

해결책

Answering to myself. I was making a bunch of mistakes, corrected those and uploaded a full working example here. Things I've learned from this:

  • call the file transfer from the "buddy-signed-on" signal and never from the "signed-on" signal.

  • There seems to be three ways to do this: using purple_xfer_* , serv_send_file, and the one I used, prpl->send_file.

Hope this helps other people that are, as me, learning libpurple.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top