-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
We used strtol() on a number of places to convert into uid_t or gid_t from a string representation such as LDAP attribute, but on some platforms, unsigned long might be necessary to store big id_t values.
This patch converts to using strtoul() instead.
Fixes: #650
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 10/18/2010 10:25 AM, Jakub Hrozek wrote:
We used strtol() on a number of places to convert into uid_t or gid_t from a string representation such as LDAP attribute, but on some platforms, unsigned long might be necessary to store big id_t values.
This patch converts to using strtoul() instead.
Fixes: #650
Nack. Throws a new warning:
cc1: warnings being treated as errors ../src/util/find_uid.c: In function ‘get_uid_from_pid’: ../src/util/find_uid.c:146: error: comparison of unsigned expression < 0 is always false
- -- Stephen Gallagher RHCE 804006346421761
Delivering value year after year. Red Hat ranks #1 in value among software vendors. http://www.redhat.com/promo/vendor/
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 10/18/2010 05:40 PM, Stephen Gallagher wrote:
On 10/18/2010 10:25 AM, Jakub Hrozek wrote:
We used strtol() on a number of places to convert into uid_t or gid_t from a string representation such as LDAP attribute, but on some platforms, unsigned long might be necessary to store big id_t values.
This patch converts to using strtoul() instead.
Fixes: #650
Nack. Throws a new warning:
cc1: warnings being treated as errors ../src/util/find_uid.c: In function get_uid_from_pid: ../src/util/find_uid.c:146: error: comparison of unsigned expression < 0 is always false
Thanks for catching that. Updated patch attached.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 10/18/2010 12:08 PM, Jakub Hrozek wrote:
On 10/18/2010 05:40 PM, Stephen Gallagher wrote:
On 10/18/2010 10:25 AM, Jakub Hrozek wrote:
We used strtol() on a number of places to convert into uid_t or gid_t from a string representation such as LDAP attribute, but on some platforms, unsigned long might be necessary to store big id_t values.
This patch converts to using strtoul() instead.
Fixes: #650
Nack. Throws a new warning:
cc1: warnings being treated as errors ../src/util/find_uid.c: In function get_uid_from_pid: ../src/util/find_uid.c:146: error: comparison of unsigned expression < 0 is always false
Thanks for catching that. Updated patch attached.
Ack.
Would you mind also producing a version that will apply on the 1.2.x branch?
- -- Stephen Gallagher RHCE 804006346421761
Delivering value year after year. Red Hat ranks #1 in value among software vendors. http://www.redhat.com/promo/vendor/
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 10/18/2010 01:09 PM, Stephen Gallagher wrote:
On 10/18/2010 12:08 PM, Jakub Hrozek wrote:
On 10/18/2010 05:40 PM, Stephen Gallagher wrote:
On 10/18/2010 10:25 AM, Jakub Hrozek wrote:
We used strtol() on a number of places to convert into uid_t or gid_t from a string representation such as LDAP attribute, but on some platforms, unsigned long might be necessary to store big id_t values.
This patch converts to using strtoul() instead.
Fixes: #650
Nack. Throws a new warning:
cc1: warnings being treated as errors ../src/util/find_uid.c: In function get_uid_from_pid: ../src/util/find_uid.c:146: error: comparison of unsigned expression < 0 is always false
Thanks for catching that. Updated patch attached.
Ack.
Would you mind also producing a version that will apply on the 1.2.x branch?
Pushed to master.
- -- Stephen Gallagher RHCE 804006346421761
Delivering value year after year. Red Hat ranks #1 in value among software vendors. http://www.redhat.com/promo/vendor/
sssd-devel@lists.fedorahosted.org