source/AccessorySDK/External/Curve25519/curve25519-test.c
static void _curve25519_djb_doit(curve25519_f inF, unsigned char *ek,unsigned char *e,unsigned char *k, int print)
{
  int i;

  if (print) {
    for (i = 0;i < 32;++i) printf("%02x",(unsigned int) e[i]); printf(" ");
    for (i = 0;i < 32;++i) printf("%02x",(unsigned int) k[i]); printf(" ");
  }
  inF(ek,e,k);
  if (print) {
    for (i = 0;i < 32;++i) printf("%02x",(unsigned int) ek[i]); printf("\n");
  }
}
//===========================================================================================================================
//	curve25519_djb_test
//
//	From DJB's pubic domain test code, modified to let you turn off printing. Maintained his style here for diff'ing.
//===========================================================================================================================
curve25519_djb_test
From DJB's pubic domain test code, modified to let you turn off printing. Maintained his style here for diff'ing.
curve25519_djb_test From DJB ' s pubic domain test code modified to let you turn off printing . Maintained his style here for diff ' ing .
static void _curve25519_djb_doit(curve25519_f inF, unsigned char *ek,unsigned char *e,unsigned char *k, int print)
{
  int i;
  if (print) {
    for (i = 0;i < 32;++i) printf("%02x",(unsigned int) e[i]); printf(" ");
    for (i = 0;i < 32;++i) printf("%02x",(unsigned int) k[i]); printf(" ");
  }
  inF(ek,e,k);
  if (print) {
    for (i = 0;i < 32;++i) printf("%02x",(unsigned int) ek[i]); printf("\n");
  }
}
static void _curve25519_djb_doit ( curve25519_f inF , unsigned char * ek , unsigned char * e , unsigned char * k , int print ) { int i ; if ( print ) { for ( i = 0 ; i < 32 ; ++ i ) printf ( " " , ( unsigned int ) e [ i ] ) ; printf ( " " ) ; for ( i = 0 ; i < 32 ; ++ i ) printf ( " " , ( unsigned int ) k [ i ] ) ; printf ( " " ) ; } inF ( ek , e , k ) ; if ( print ) { for ( i = 0 ; i < 32 ; ++ i ) printf ( " " , ( unsigned int ) ek [ i ] ) ; printf ( " \n " ) ; } }
curve25519_djb_test
From DJB's pubic domain test code, modified to let you turn off printing.
curve25519_djb_test From DJB ' s pubic domain test code modified to let you turn off printing .