What is u_int32_t?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • kevinkwh
    New Member
    • Feb 2010
    • 13

    What is u_int32_t?

    Hi I'm doing porting from Linux to Visual C ++. And I found quite a few errors. What is u_int32_t ? I can't find it in Visual C ++? Is it only available in Linux? Which type should I use in Visual C++? Thanks in advance !!!

    Kevin
  • jjdot
    New Member
    • Feb 2011
    • 11

    #2
    It is uint32_t and not u_int32_t. Normally you just have
    to include:

    #include <stdint.h>

    on a 32 bits machine you can replace it by
    #define uint32_t unsigned int
    on a 64 bits machine I think you should work too but.

    Comment

    • kevinkwh
      New Member
      • Feb 2010
      • 13

      #3
      Thanks you !!! but this u_int32_t is ok with Linux. My colleague told me . No idea what to do next !!!

      Comment

      • jjdot
        New Member
        • Feb 2011
        • 11

        #4
        Ok. I'ignored existence of this type. In fact I always
        use stdint.h. I found u_int32_t definition in header file
        #include <sys/types.h>

        I think the simplest way to do is to
        #include <stdint.h>
        #define u_int32_t uint32_t

        Comment

        Working...