mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
Merge pull request #1318 from int2001/qrz_no_save_file
Don't save and process empty files for QRZ
This commit is contained in:
@@ -370,11 +370,11 @@ class Qrz extends CI_Controller {
|
||||
curl_setopt( $ch, CURLOPT_USERAGENT, 'Wavelog/'.$this->optionslib->get_option('version'));
|
||||
|
||||
$content = htmlspecialchars_decode(curl_exec($ch));
|
||||
file_put_contents($file, $content);
|
||||
if (strlen(file_get_contents($file, false, null, 0, 100))!=100) {
|
||||
if (strlen($content)<100) {
|
||||
$result = "QRZ downloading failed, either due to it being down or incorrect logins.";
|
||||
return "false";
|
||||
}
|
||||
file_put_contents($file, $content);
|
||||
|
||||
ini_set('memory_limit', '-1');
|
||||
$result = $this->loadFromFile($file, $station_ids);
|
||||
|
||||
Reference in New Issue
Block a user