global and static variable in a class delivered in a DLL

Discussion in 'C Programming' started by George2, Apr 9, 2008.

  1. George2

    George2

    Joined:
    Feb 12, 2008
    Messages:
    108
    Hello everyone,


    If we define global variable and static variable of a class, which are implemented in a DLL. My questions are,

    1. All instances of class share the single copy of global variable and static variable of class? If yes, I need to have some synchronization approach on them.

    2. Is it safe to use global variable and static (public) variable after DLL unloads?


    thanks in advance,
    George
    George2, Apr 9, 2008
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Joe Fallon
    Replies:
    5
    Views:
    3,510
    Joe Fallon
    Jul 28, 2005
  2. Marcin Vorbrodt

    Global static variable vs static method

    Marcin Vorbrodt, Sep 5, 2003, in forum: C++
    Replies:
    3
    Views:
    5,415
    Denis Perelyubskiy
    Sep 5, 2003
  3. Sam
    Replies:
    4
    Views:
    470
    The Directive
    Jan 13, 2004
  4. drmario
    Replies:
    4
    Views:
    699
    James Kanze
    Apr 15, 2008
  5. H. Simpson
    Replies:
    4
    Views:
    258
    H. Simpson
    Aug 3, 2004
Loading...

Share This Page