message: validation checks on create, issue, and transfer actions
diff: @@ -47,7 +47,7 @@ namespace eosio {
  };
  struct fee_schedule {
  - auto primary_key() const { return 0; }
  + uint64_t primary_key()const { return 0; }
  array<extended_asset,7> fee_per_length;
  EOSLIB_SERIALIZE( fee_schedule, (fee_per_length) )
  @@ -129,7 +129,7 @@ namespace eosio {
  */
  void create_currency( const create& c ) {
  auto sym = c.maximum_supply.symbol;
  - // eosio_assert( sym.is_valid(), "invalid symbol name" );
  + eosio_assert( sym.is_valid(), "invalid symbol name" );
  stats statstable( _contract, sym.name() );
  auto existing = statstable.find( sym.name() );
  @@ -177,7 +177,8 @@ namespace eosio {
  const auto& st = statstable.get( sym );
  require_auth( st.issuer );
  - eosio_assert( i.quantity.amount > 0, "cannot transfer negative quantity" );
  + eosio_assert( i.quantity.is_valid(), "invalid quantity" );
  + eosio_assert( i.quantity.amount > 0, "must issue positive quantity" );
  statstable.modify( st, 0, [&]( auto& s ) {
  s.supply.amount += i.quantity.amount;
  @@ -198,7 +199,8 @@ namespace eosio {
  require_recipient( t.to );
  - eosio_assert( t.quantity.amount > 0, "cannot transfer negative quantity" );
  + eosio_assert( t.quantity.is_valid(), "invalid quantity" );
  + eosio_assert( t.quantity.amount > 0, "must transfer positive quantity" );
  sub_balance( t.from, t.quantity, st );
  add_balance( t.to, t.quantity, st, t.from );
  }
  