[PATCH] integer out of range for L format code

Radek Vykydal rvykydal at redhat.com
Wed Aug 22 14:43:49 UTC 2012


Looks good.

On 08/22/2012 03:32 PM, Mark Hamzy wrote:
> http://docs.python.org/library/ctypes.html#specifying-the-required-argument-types-function-prototypes
> and http://docs.python.org/library/ctypes.html#return-types need to be followed for the call to
> nm_utils.nm_utils_ip4_prefix_to_netmask.
>
> ---
>   pyanaconda/ui/gui/spokes/network.py |    2 ++
>   1 file changed, 2 insertions(+)
>
> diff --git a/pyanaconda/ui/gui/spokes/network.py b/pyanaconda/ui/gui/spokes/network.py
> index e0f3792..329be82 100644
> --- a/pyanaconda/ui/gui/spokes/network.py
> +++ b/pyanaconda/ui/gui/spokes/network.py
> @@ -619,6 +619,8 @@ class NetworkControlBox():
>               self._set_device_info_value(dt, "route", gateway)
>               if dt == "wired":
>                   prefix = ipv4cfg.get_addresses()[0].get_prefix()
> +                nm_utils.nm_utils_ip4_prefix_to_netmask.argtypes = [ctypes.c_uint32]
> +                nm_utils.nm_utils_ip4_prefix_to_netmask.restype = ctypes.c_uint32
>                   netmask = nm_utils.nm_utils_ip4_prefix_to_netmask(prefix)
>                   netmask = socket.inet_ntoa(struct.pack('=L', netmask))
>                   self._set_device_info_value(dt, "subnet", netmask)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.fedorahosted.org/pipermail/anaconda-patches/attachments/20120822/ca682b7d/attachment.html>


More information about the anaconda-patches mailing list