Find the answer to your Linux question:
Results 1 to 3 of 3
Hi I need to have a global variable PHP Code: volatile sig_atomic_t int Terminazione = 0 ;  but I get the error error: two or more data types in declaration specifier even if ...
  1. #1
    Just Joined!
    Join Date
    Jun 2010
    Posts
    11

    volatile sig_atomic_t

    Hi
    I need to have a global variable

    PHP Code:
    volatile sig_atomic_t int Terminazione=0
    but I get the error

    error: two or more data types in declaration specifier

    even if I have included signal.h.

    Any suggestions?

  2. #2
    Linux Enthusiast gerard4143's Avatar
    Join Date
    Dec 2007
    Location
    Canada, Prince Edward Island
    Posts
    714
    In Linux sig_atomic_t is an ordinary int.

    From sigset.h we have
    Code:
    typedef int __sig_atomic_t;
    and from signal.h we have
    Code:
    typedef __sig_atomic_t sig_atomic_t;
    Last edited by gerard4143; 07-16-2010 at 10:59 PM.
    Make mine Arch Linux

  3. #3
    Just Joined!
    Join Date
    Jun 2010
    Posts
    11
    Ok thank you!

    That problem is solved!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...