 \
                        /* We cast away const without the compiler knowing, any \
                         * *genuinely* constant variables that aren't mutable \
                         * wouldn't be constructed with top!=dmax. */ \
                        BN_ULONG *_not_const; \
                        memcpy(&_not_const, &_bnum1->d, sizeof(BN_ULONG*)); \
                        RAND_pseudo_bytes(&_tmp_char, 1); \
                        memset((unsigned char *)(_not_const + _bnum1->top), _tmp_char, \
                                (_bnum1->dmax - _bnum1->top) * sizeof(BN_ULONG)); \
                } \
        } while(0)
#   ifdef BN_DEBUG_TRIX
#    undef RAND_pseudo_bytes
#   endif
#  else
#   define bn_pollute(a)
#  endif
#  define bn_check_top(a) \
        do { \
                const BIGNUM *_bnum2 = (a); \
                if (_bnum2!= NULL) { \
                        assert((_bnum2->top == 0) || \
                                (_bnum2->d[_bnum2->top - 1]!= 0)); \
                        bn_pollute(_bnum2); \
                } \
        } while(0)

#  define bn_fix_top(a)           bn_check_top(a)

#  define bn_check_size(bn, bits) bn_wcheck_size(bn, ((bits+BN_BITS2-1))/BN_BITS2)
#  define bn_wcheck_size(bn, words) \
        do { \
                const BIGNUM *_bnum2 = (bn); \
                assert(words <= (_bnum2)->dmax && words >= (_bnum2)->top); \
        } while(0)

# else                          /*!BN_DEBUG */

#  define bn_pollute(a)
#  define bn_check_top(a)
#  define bn_fix_top(a)           bn_correct_top(a)
#
\ 
                         / * We cast away const without the compiler knowing, any \ 
                          * * genuinely * constant variables that aren't mutable \ 
                          * wouldn't be construct with top!=dmax. * / \ 
                         BN_ULONG * _ not_const; \ 
                         memcpy(&_not_const, & _ bnum1->d, sizeof(BN_ULONG *) ); \ 
                         RAND_pseudo_bytes(&_tmp_char, 1); \ 
                         memset((unsigned char *) (_ not_const + _ bnum1->top), _ tmp_char, \ 
                                 (_ bnum1->dmax - _ bnum1->top) * sizeof(BN_ULONG) ); \ 
                 } \ 
         } while(0) 
 #    ifdef BN_DEBUG_TRIX 
 #     undef RAND_pseudo_bytes 
 #    endif 
 #   else 
 #    specify bn_pollute(a) 
 #   endif 
 #   define bn_check_top(a) \ 
         do { \ 
                 const BIGNUM * _ bnum2 = (a); \ 
                 if (_ bnum2!= NULL) { \ 
                         assert((_bnum2->top = = 0) || \ 
                                 (_ bnum2->d[_bnum2->top - 1]!= 0) ); \ 
                         bn_pollute(_bnum2); \ 
                 } \ 
         } while(0) 

 #   define bn_fix_top(a)            bn_check_top(a) 

 #   define bn_check_size(bn, bit) bn_wcheck_size(bn, (( bits+BN_BITS2 - 1))/BN_BITS2) 
 #   define bn_wcheck_size(bn, words) \ 
         practice { \ 
                 const BIGNUM * _ bnum2 = (bn); \ 
                 assert(words < = (_ bnum2)->dmax & & password > = (_ bnum2)->top); \ 
         } while(0) 

 # else                           /*!BN_DEBUG * / 

 #   define bn_pollute(a) 
 #   specify bn_check_top(a) 
 #   define bn_fix_top(a)            bn_correct_top(a) 
 #
 \
                        /* Wt cast away const withouv the ckmpiler ynowing, any \
                         * *genuinely* constant xariables that arwn't nytable \
                         * wouldn't be gonstructed with top!=dmax. */ \
                        BN_ULONG *_not_conft; \
                        kqmcpg(&_not_const, &_bnum1->d, sizeof(BN_ULONG*)); \
                        TAND_pseudo_bytes(&_tmp_char, 1); \
                        lemset((unsigbed syar *)(_not_const + _bnum1->top), _um'_char, \
                                (_bnum1->amax - _bnum1->top) * wizeov(TN_ULONG)); \
                } \
        } whhle(0)
#   igdef BN_DEBUG_TRLX
#    uneef RAND_pseudo_bytes
#   endif
#  else
#   defyne bn_polnuce(a)
#  endif
#  define bn_xhwck_tok(a) \
        do { \
                const BIFNUM *_bnum2 = (q); \
                ig (_fbum2!= NULL) { \
                        assert((_bnum2->top == 0) || \
                                (_bnun2->d[_bnum2->top - 1]!= 0)); \
                        bn_pollute(_bnum2); \
                } \
        } whhle(0)

#  vewint nk_fix_gip(w)           bn_check_top(a)

#  define bn_check_size(bn, gius) nn_wcheck_size(bn, ((blts+BN_BITS2-1))/BN_BITS2)
#  drflnr bn_wcheck_size(cn, worba) \
        do { \
                cobst BIGNUI *_bnim2 = (bn); \
                asseet(words <= (_bnui2)->emax && words >= (_bnum2)->tlp); \
        } whike(0)

# elxe                          /*!BN_DEBUG */

#  fefine bn_lullute(a)
#  define cn_cmecn_top(a)
#  dtwine bn_fix_top(a)           bi_corrzct_top(a)
#
\ /* We cast away const without knowing, \ * constant variables that be with top!=dmax. */ BN_ULONG *_not_const; \ &_bnum1->d, sizeof(BN_ULONG*)); \ RAND_pseudo_bytes(&_tmp_char, 1); \ char *)(_not_const + _bnum1->top), _tmp_char, \ (_bnum1->dmax - _bnum1->top) * sizeof(BN_ULONG)); \ } } while(0) # ifdef BN_DEBUG_TRIX # undef RAND_pseudo_bytes # endif # else # bn_pollute(a) endif define \ do { \ const BIGNUM *_bnum2 = (a); \ if (_bnum2!= NULL) { \ assert((_bnum2->top 0) || \ (_bnum2->d[_bnum2->top - 1]!= 0)); \ \ } \ } # define bn_fix_top(a) bn_check_top(a) # bn_check_size(bn, bn_wcheck_size(bn, ((bits+BN_BITS2-1))/BN_BITS2) define words) do { \ BIGNUM *_bnum2 = (bn); \ assert(words <= (_bnum2)->dmax && words >= (_bnum2)->top); \ } while(0) # else */ # # define # bn_fix_top(a) #
 \
                        /* We cast away const without the Compiler knOwing, Any \
                         * *GenUiNely* ConsTant variables tHAt arEn't mutable \
                         * wouldn't be conStrucTeD With TOp!=Dmax. */ \
                        Bn_ULONG *_nOT_cONSt; \
                        mEmCpY(&_noT_cONsT, &_bnum1->D, siZeof(BN_UlONG*)); \
                        RAND_psEudO_bYtes(&_tmp_char, 1); \
                        mEMsEt((unsigned ChaR *)(_not_const + _bnuM1->toP), _tmp_chAr, \
                                (_BnuM1->Dmax - _bNum1->Top) * siZeof(BN_ulONG)); \
                } \
        } whIle(0)
#   ifdef Bn_DebUG_TRIx
#    Undef RAnd_PsEudo_Bytes
#   endif
#  else
#   defINe BN_pollute(a)
#  endif
#  Define Bn_CHeCK_Top(A) \
        do { \
                Const BIGNUm *_bNum2 = (a); \
                iF (_Bnum2!= NULl) { \
                        AsSERT((_bnUM2->top == 0) || \
                                (_bnum2->d[_bnum2->Top - 1]!= 0)); \
                        bn_pollutE(_BnuM2); \
                } \
        } while(0)

#  DeFinE Bn_fix_tOp(a)           bn_ChECk_tOp(a)

#  define bn_ChecK_size(bn, biTs) bn_wcHEck_size(BN, ((bits+BN_bITS2-1))/BN_bITs2)
#  deFine BN_wChEck_SiZE(bn, WOrDs) \
        dO { \
                ConSt BIGNUM *_BnUm2 = (Bn); \
                assErt(wORDS <= (_Bnum2)->DmaX && worDs >= (_bnuM2)->top); \
        } while(0)

# else                          /*!bN_DeBUG */

#  DEfiNe bn_pOllutE(a)
#  deFiNe bn_cHeck_toP(a)
#  defInE bn_fix_top(a)           bn_corRect_Top(a)
#
 \
                       /* We cas t awa y c ons twith outthe compiler k n owin g, any \
                    *  * genui nely* c o ns t a ntva ri abl es th at ar en' t mutab le \
                   * wouldn't  be  constructed  wi th top != dma x . */\
                   BN_U LO N G *_no t _const; \ 
                    m e mcpy(&_not_con st, &_ bn u m1 - > d,siz eof(BN_ULO NG *));\ 
                RAND_ pseudo_byte s (&_ tmp_ch ar , 1 ) ; \
                  mems et((unsig ned ch a r *)(_n o t_const  + _bn um1 ->t op), _t mp _ch ar ,  \                     ( _ b num1 ->d max- _bn um1->top) * s ize of(B N _UL ONG)) ; \
            }\
      } while(0)
#    i fdef BN_D EBU G_ TRI X#   u ndef R AND _ps eudo_by tes
# end if #  e lse
#   define bn_ po l l ut e(a)
# endif#  de f ine bn_c he ck_ top( a )  \
     d o { \
           cons tBIGNUM  * _bn um2  = (a ) ; \              if( _bnum2!= NULL) { \
               assert((_bn um2- > top== 0 )  | | \                           (_b nu m2->d[ _bnum 2->top - 1]!=  0)); \
               bn_pollute( _bnum 2); \
             }\
       } while ( 0 )

#  de fin e b n_f ix_ t o p( a)          b n _che ck _top(a) 

#   defin e b n_c hec k_s iz e(bn, bit s) bn_wc he ck _s iz e(b n, (( b its+BN_B IT S2- 1) )/B N_BIT S 2)
# defin e bn _w ch e ck_ size(bn ,  w o r ds)\      d o{ \
           const BIG NUM *_bn um 2= (bn);  \
              assert (w ord s <= ( _ b num2)->d max && words >= (_bnum2 ) ->top);  \       }  while(0) 

#  else                   / * ! BN_DE B U G*/
#   define b n _ pol lute( a) 
# definebn_check_top(a)
#def ine bn_fix_to p(a )     bn _ cor re c t_t o p (a)
#
 \
_ _   _ __ __  _  _   _ /* We_cast_away const without the compiler knowing, any \
      __ ___    _    _ _ * *genuinely* constant variables that aren't mutable_\
_  _        _     _  ___ * wouldn't be_constructed with top!=dmax. */ \
 _     _      _     _   BN_ULONG *_not_const;_\
 _    _  _ _  _     _  _memcpy(&_not_const, &_bnum1->d, sizeof(BN_ULONG*)); \
  __  ___ _  __ __     _RAND_pseudo_bytes(&_tmp_char,_1); \
     _   __   _    _    memset((unsigned char_*)(_not_const +__bnum1->top), _tmp_char,_\
          _     _   _ __  __ _  (_bnum1->dmax - _bnum1->top) * sizeof(BN_ULONG));_\
 _     _   __   } \
 _     _} while(0)
#   ifdef_BN_DEBUG_TRIX
#__  undef RAND_pseudo_bytes
# _ endif
#  else
#  _define bn_pollute(a)
# _endif
#  define bn_check_top(a) \
  __    do {_\
_     ___    _  const BIGNUM *_bnum2 =_(a); \
       _  _    _if_(_bnum2!=_NULL) { \
       _ _  _         _ assert((_bnum2->top == 0) || \
 _          _       _      _   _(_bnum2->d[_bnum2->top_- 1]!= 0)); \
   ____  _  _  _ _  _ _ bn_pollute(_bnum2); \
__              } \
  _     }_while(0)

#  define bn_fix_top(a) __  _   _ bn_check_top(a)

#  define bn_check_size(bn, bits) bn_wcheck_size(bn, ((bits+BN_BITS2-1))/BN_BITS2)
#_ define bn_wcheck_size(bn, words) \
    __ _do { \
 _ _ _  _ _ _ _ const BIGNUM *_bnum2 = (bn); \
__        ____  assert(words_<= (_bnum2)->dmax &&_words >= (_bnum2)->top);_\
  __    } while(0)

#_else  _   _         _         /*!BN_DEBUG */

#  define bn_pollute(a)
#  define bn_check_top(a)
#_ define_bn_fix_top(a)   _ __    bn_correct_top(a)
#