From: Neal Norwitz Date: Tue, 30 May 2006 03:18:50 +0000 (+0000) Subject: Simplify further by using AddStringConstant X-Git-Tag: v2.5b1~346 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1e44ca94acc5e93ab21aacded7046ee5171c40cd;p=python Simplify further by using AddStringConstant --- diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c index 5f7a520cf4..847a1948b8 100644 --- a/Modules/socketmodule.c +++ b/Modules/socketmodule.c @@ -4362,10 +4362,8 @@ init_socket(void) PyModule_AddIntConstant(m, "BTPROTO_SCO", BTPROTO_SCO); #endif PyModule_AddIntConstant(m, "BTPROTO_RFCOMM", BTPROTO_RFCOMM); - PyModule_AddObject(m, "BDADDR_ANY", - PyString_FromString("00:00:00:00:00:00")); - PyModule_AddObject(m, "BDADDR_LOCAL", - PyString_FromString("00:00:00:FF:FF:FF")); + PyModule_AddStringConstant(m, "BDADDR_ANY", "00:00:00:00:00:00"); + PyModule_AddStringConstant(m, "BDADDR_LOCAL", "00:00:00:FF:FF:FF"); #endif #ifdef HAVE_NETPACKET_PACKET_H