Skip to content

Commit 17fbefd

Browse files
committed
Remove unsued code
1 parent 5ee128f commit 17fbefd

File tree

3 files changed

+1
-66
lines changed

3 files changed

+1
-66
lines changed

ChangeLog

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
* Remove unused code. ( Boris Zentner )
12
1.2.7 2011-08-23
23
* Add example test_netspeedcell.py ( Boris Zentner )
34
1.2.6 2011-06-06

py_GeoIP.c

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -253,30 +253,6 @@ void GeoIP_SetItemInt(PyObject *dict, const char * name, int value) {
253253
Py_DECREF(valueObj);
254254
}
255255

256-
void GeoIP_SetConfItemInt(PyObject *dict, const char * name, int value) {
257-
PyObject * nameObj;
258-
PyObject * valueObj;
259-
nameObj = Py_BuildValue("s",name);
260-
valueObj = value == GEOIP_UNKNOWN_CONF
261-
? Py_BuildValue("")
262-
: Py_BuildValue("i",value);
263-
PyDict_SetItem(dict,nameObj,valueObj);
264-
Py_DECREF(nameObj);
265-
Py_DECREF(valueObj);
266-
}
267-
268-
void GeoIP_SetAccuracyItemInt(PyObject *dict, const char * name, int value) {
269-
PyObject * nameObj;
270-
PyObject * valueObj;
271-
nameObj = Py_BuildValue("s",name);
272-
valueObj = value == GEOIP_UNKNOWN_ACCURACY_RADIUS
273-
? Py_BuildValue("")
274-
: Py_BuildValue("i",value);
275-
PyDict_SetItem(dict,nameObj,valueObj);
276-
Py_DECREF(nameObj);
277-
Py_DECREF(valueObj);
278-
}
279-
280256
static PyObject * GeoIP_region_populate_dict(GeoIPRegion * gir) {
281257
PyObject * retval;
282258
const char * region_name = NULL;
@@ -319,20 +295,6 @@ static PyObject * GeoIP_populate_dict(GeoIP* gi, GeoIPRecord *gir) {
319295
GeoIP_SetItemInt(retval,"area_code",gir->area_code);
320296
}
321297

322-
/*
323-
* drop support for Confidence and Accuracy Database
324-
* for now
325-
326-
if ( gi->databaseType != GEOIP_CITY_EDITION_REV1 ){
327-
GeoIP_SetConfItemInt(retval, "country_conf", gir->country_conf );
328-
GeoIP_SetConfItemInt(retval, "region_conf", gir->region_conf );
329-
GeoIP_SetConfItemInt(retval, "city_conf", gir->city_conf );
330-
GeoIP_SetConfItemInt(retval, "postal_conf", gir->postal_conf );
331-
332-
GeoIP_SetAccuracyItemInt(retval, "accuracy_radius", gir->accuracy_radius );
333-
334-
*/
335-
336298
GeoIPRecord_delete(gir);
337299
return retval;
338300
}

test_city_acc.py

Lines changed: 0 additions & 28 deletions
This file was deleted.

0 commit comments

Comments
 (0)