Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 526244
Collapse All | Expand All

(-)file_not_specified_in_diff (-11 / +15 lines)
Line  Link Here
0
-- geoip.c.orig        2014-05-01 20:44:31.000000000 +0300
0
++ geoip.c     2014-10-22 20:54:31.000000000 +0300
Lines 548-562 Link Here
548
       }
548
       }
549
549
550
       if (GeoIP_db_avail(GEOIP_CITY_EDITION_REV1) || GeoIP_db_avail(GEOIP_CITY_EDITION_REV0)) {
550
       if (GeoIP_db_avail(GEOIP_CITY_EDITION_REV1) || GeoIP_db_avail(GEOIP_CITY_EDITION_REV0)) {
551
               if (GeoIP_db_avail(GEOIP_CITY_EDITION_REV1)) {
551
               gi = GeoIP_open_type(GEOIP_CITY_EDITION_REV0, GEOIP_STANDARD);
552
                       gi = GeoIP_open_type(GEOIP_CITY_EDITION_REV1, GEOIP_STANDARD);
552
               if (NULL == gi) { gi = GeoIP_open_type(GEOIP_CITY_EDITION_REV1, GEOIP_STANDARD); }
553
               } else {
553
               if (NULL == gi) { 
554
                       gi = GeoIP_open_type(GEOIP_CITY_EDITION_REV0, GEOIP_STANDARD);
554
                       php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't open database file");
555
                       return;
555
               }
556
               }
556
       }   else {
557
       } else {
557
               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Required database not available at %s.", GeoIPDBFileName[GEOIP_CITY_EDITION_REV0]);
558
               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Required database not available at %s.", GeoIPDBFileName[GEOIP_CITY_EDITION_REV0]);
558
               return;
559
               return;
559
       }
560
       }
561
562
560
       gir = GeoIP_record_by_name(gi, hostname);
563
       gir = GeoIP_record_by_name(gi, hostname);
561
564
562
       GeoIP_delete(gi);
565
       GeoIP_delete(gi);
Lines 628-638 Link Here
628
       }
631
       }
629
632
630
       if (GeoIP_db_avail(GEOIP_REGION_EDITION_REV0) || GeoIP_db_avail(GEOIP_REGION_EDITION_REV1)) {
633
       if (GeoIP_db_avail(GEOIP_REGION_EDITION_REV0) || GeoIP_db_avail(GEOIP_REGION_EDITION_REV1)) {
631
               if (GeoIP_db_avail(GEOIP_REGION_EDITION_REV1)) {
634
               gi = GeoIP_open_type(GEOIP_REGION_EDITION_REV0, GEOIP_STANDARD);
632
                       gi = GeoIP_open_type(GEOIP_REGION_EDITION_REV1, GEOIP_STANDARD);
635
               if (NULL == gi) { gi = GeoIP_open_type(GEOIP_REGION_EDITION_REV1, GEOIP_STANDARD); }
633
               } else {
636
               if (NULL == gi) { 
634
                       gi = GeoIP_open_type(GEOIP_REGION_EDITION_REV0, GEOIP_STANDARD);
637
                        php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't open database file");
635
               }
638
                        return;
639
               }
636
       }   else {
640
       }   else {
637
               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Required database not available at %s.", GeoIPDBFileName[GEOIP_REGION_EDITION_REV0]);
641
               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Required database not available at %s.", GeoIPDBFileName[GEOIP_REGION_EDITION_REV0]);
638
               return;
642
               return;

Return to bug 526244