- Timestamp:
- 2010-04-25T19:22:02Z (15 years ago)
- Branches:
- master
- Children:
- b2bc25c
- Parents:
- da2efd4
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lib/oauth.c
rda2efd4 r346dfd9 253 253 254 254 oauth_params_set( ¶ms, "oauth_version", "1.0" ); 255 oauth_params_set( ¶ms, "oauth_callback", "oob" );256 255 257 256 params_s = oauth_params_string( params ); … … 281 280 } 282 281 283 void oauth_request_token_done( struct http_request *req );282 static void oauth_request_token_done( struct http_request *req ); 284 283 285 284 void *oauth_request_token( const char *url, oauth_cb func, void *data ) 286 285 { 287 286 struct oauth_info *st = g_new0( struct oauth_info, 1 ); 287 GSList *params = NULL; 288 288 289 289 st->func = func; 290 290 st->data = data; 291 291 292 oauth_params_add( ¶ms, "oauth_callback", "oob" ); 293 292 294 return oauth_post_request( url, NULL, oauth_request_token_done, st ); 293 295 } 294 296 295 void oauth_request_token_done( struct http_request *req )297 static void oauth_request_token_done( struct http_request *req ) 296 298 { 297 299 struct oauth_info *st = req->data; … … 309 311 } 310 312 311 st->func( st ); 312 } 313 //st->func( st ); 314 } 315 316 static void oauth_access_token_done( struct http_request *req ); 317 318 void *oauth_access_token( const char *url, const char *pin, struct oauth_info *st ) 319 { 320 GSList *params = NULL; 321 322 oauth_params_add( ¶ms, "oauth_token", st->token ); 323 oauth_params_add( ¶ms, "oauth_verifier", pin ); 324 325 return oauth_post_request( url, ¶ms, oauth_access_token_done, st ); 326 } 327 328 static void oauth_access_token_done( struct http_request *req ) 329 { 330 }
Note: See TracChangeset
for help on using the changeset viewer.