-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi Fret.
On 09/03/2010 07:38 AM, fret wrote: > I downloaded and compiled liboauth with a view towards using it in > some email software. I made some simple changes to make it compile > nicely on VC6: Many Thanks. I'll apply them. I also just noticed: [V]I not only messed up the indenting but there's a typo in the function name: independent lacks a 'd'. stay tuned. Cheers! robin > Index: src/oauth.c > =================================================================== > --- src/oauth.c (revision 1238) > +++ src/oauth.c (working copy) > @@ -863,12 +863,18 @@ > * > * returns 0 (false) if strings are not equal, and 1 (true) if > strings are equal. > */ > -int oauth_time_indepenent_equals_n(const char* a, const char* b, > size_t len_a, size_t len_b) { > - if (a == NULL) return (b == NULL); > - else if (b == NULL) return 0; > - else if (len_b == 0) return (len_a == 0); > - int diff = len_a ^ len_b; > - int i,j = 0; > +int oauth_time_indepenent_equals_n(const char* a, const char* b, > size_t len_a, size_t len_b) > +{ > + int diff, i, j; > + if (a == NULL) > + return (b == NULL); > + else if (b == NULL) > + return 0; > + else if (len_b == 0) > + return (len_a == 0); > + > + diff = len_a ^ len_b; > + i,j = 0; > for (i=0; i<len_a; ++i) { > diff |= a[i] ^ b[j]; > j = (j+1) % len_b; > Index: src/oauth.h > =================================================================== > --- src/oauth.h (revision 1238) > +++ src/oauth.h (working copy) > @@ -643,7 +643,7 @@ > * Multiple header elements can be passed separating them with "\r\n" > * @return returned HTTP reply or NULL on error > */ > -char *oauth_post_file (const char *u, const char *fn, size_t len, > const char *customheader); > +char *oauth_post_file (const char *u, const char *fn, const size_t > len, const char *customheader); > > /** > * http post raw data > -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iEYEARECAAYFAkyI/AYACgkQeVUk8U+VK0IcHgCeIYO1ZYSRroSc/wf8J5Kitsij ZugAoJ7a7dqhm7ojsqaWIthKEpgcIBj/ =38Xv -----END PGP SIGNATURE----- -- You received this message because you are subscribed to the Google Groups "OAuth" group. To post to this group, send email to oa...@googlegroups.com. To unsubscribe from this group, send email to oauth+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/oauth?hl=en.