Re: FFI, cURL and function callback

  • From: Szabó Antal <szabo.antal.92@xxxxxxxxx>
  • To: luajit@xxxxxxxxxxxxx
  • Date: Sun, 24 Mar 2013 13:40:09 +0100

2013/3/24 pingon begand <sbronfion@xxxxxxxxx>:
> I want to use the cURL library in order to retrieve some website contents as
> strings. However one need to have a function callback in order to do this.
> Is this possible to achieve such things with plain LuaJIT and FFI?

You can cast a lua function into a c funtion pointer type, and pass
that to curl.

Other related posts: