// Used to write the data we are getting from libcurl 
Used to write the data we are getting from libcurl
Used to write the data we are getting from libcurl
fn callback(data: *const libc::c_char,
		       size: libc::size_t,
		       nmemb: libc::size_t,
		       userp: Rc<RefCell<&str>>) -> libc::size_t
{
    unsafe {
	let data_str = CStr::from_ptr(data);
	let data_slice = data_str.to_str().unwrap();
	*userp.borrow_mut() = data_slice;
	size * nmemb
    }
}
fn callback ( data : * const libc :: c_char , size : libc :: size_t , nmemb : libc :: size_t , userp : Rc < RefCell < & str > > ) -> libc :: size_t { unsafe { let data_str = CStr :: from_ptr ( data ) ; let data_slice = data_str . to_str ( ) . unwrap ( ) ; * userp . borrow_mut ( ) = data_slice ; size * nmemb } }
Used to write the data we are getting from libcurl
Used to write the data we are getting from libcurl
data
*const libc::c_char
<not_specific>
size
libc::size_t
<not_specific>
nmemb
libc::size_t
<not_specific>
userp
Rc<RefCell<&str>>
<not_specific>