hi ns-users,  

i have a little problem. i want insert a new
variable in file .h and use it in file .cpp. But a erro "undefined
reference to `hdr_pingado::p_'" occur.  My variable p may be static
because i have use it for two or more objects. when i set variable p
like a single type, for example, int, all occur correcty. however, when
i set variable p like a static type the erro above occur. what can be
happen?
 A peace of code follow below:

struct hdr_pingado {
  char ret;
  double send_time;
  static int p_;//if equal 2, then send packet
        // Header access methods
    static int off_pingado_; // required by PacketHeaderManager
    inline static int& off_pingado() { return off_pingado_; }
    inline static hdr_pingado* access(const Packet* p) {
        return (hdr_pingado*) p->access(off_pingado_);
    }
};

thank you for any help.
regards,

 Breno Caetano da Silva
Bacharel em Ciências da Computação - UFPI
Mestrando em Engenharia Elétrica
Escola de Engenharia de São Carlos - EESC
Universidade de São Paulo
Email: [EMAIL PROTECTED]
[EMAIL PROTECTED]
Fone: (+5516) 81449079
(+5516) 33738149



      Novos endereços, o Yahoo! que você conhece. Crie um email novo com a sua 
cara @ymail.com ou @rocketmail.com.
http://br.new.mail.yahoo.com/addresses

Reply via email to