Bug 2485 - lib/privileges.c, Line 495: "unsigned int *" incompatible with "int *"
lib/privileges.c, Line 495: "unsigned int *" incompatible with "int *"
Status: CLOSED FIXED
Product: Samba 3.0
Classification: Unclassified
Component: libsmbclient
3.0.11
SGI IRIX
: P3 normal
: none
Assigned To: Samba Bugzilla Account
Samba QA Contact
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-03-18 11:20 UTC by Jason Mader
Modified: 2005-08-24 10:16 UTC (History)
0 users

See Also:


Attachments
changes num to "unsigned int *" (1.36 KB, patch)
2005-03-18 11:56 UTC, Jason Mader
no flags Details
changes to lib/util_sid.c and groupdb/mapping.c (3.42 KB, patch)
2005-03-18 12:15 UTC, Jason Mader
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jason Mader 2005-03-18 11:20:50 UTC
Samba 3.0.12rc1

Compiling lib/privileges.c
cc-1164 cc: WARNING File = lib/privileges.c, Line = 495
  Argument of type "unsigned int *" is incompatible with parameter of type
          "int *".

        add_sid_to_array( &sid, &priv->sids.list, &priv->sids.count );
                                                  ^
Comment 1 Jason Mader 2005-03-18 11:56:38 UTC
Created attachment 1048 [details]
changes num to "unsigned int *"

I changed the argument num of add_sid_to_array() and related add/del sid
functions to "unsigned int *", and that compiled without warning.
Comment 2 Jason Mader 2005-03-18 12:04:02 UTC
Compiling groupdb/mapping.c
cc-1164 cc: WARNING File = groupdb/mapping.c, Line = 521
  Argument of type "int *" is incompatible with parameter of type
          "unsigned int *".

                add_sid_to_array_unique(&alias, sids, num);
                                                      ^

cc-1164 cc: WARNING File = groupdb/mapping.c, Line = 668
  Argument of type "int *" is incompatible with parameter of type
          "unsigned int *".

                add_sid_to_array(&member, closure->sids, closure->num);
                                                         ^
Comment 3 Jason Mader 2005-03-18 12:15:42 UTC
Created attachment 1049 [details]
changes to lib/util_sid.c and groupdb/mapping.c

Side effects found in mapping.c, so I've revised the patch.
Comment 4 Gerald (Jerry) Carter 2005-03-22 08:30:58 UTC
fixed by changing the SID_LIST.count declaration.
Comment 5 Gerald (Jerry) Carter 2005-08-24 10:16:24 UTC
sorry for the same, cleaning up the database to prevent unecessary reopens of bugs.