diff --git a/htdocs/admin/tools/dolibarr_export.php b/htdocs/admin/tools/dolibarr_export.php
index f88563ff512..1ad21490e4b 100644
--- a/htdocs/admin/tools/dolibarr_export.php
+++ b/htdocs/admin/tools/dolibarr_export.php
@@ -200,7 +200,6 @@ if (in_array($type, array('mysql', 'mysqli'))) {
print '
';
print '';
print '';
-
print '
';
if (!empty($conf->global->MYSQL_OLD_OPTION_DISABLE_FK)) {
diff --git a/htdocs/core/lib/files.lib.php b/htdocs/core/lib/files.lib.php
index 288a28c111a..bad0bf9f48c 100644
--- a/htdocs/core/lib/files.lib.php
+++ b/htdocs/core/lib/files.lib.php
@@ -960,18 +960,18 @@ function dol_unescapefile($filename)
*/
function dolCheckVirus($src_file)
{
- global $conf, $db;
+ global $conf;
if (!empty($conf->global->MAIN_ANTIVIRUS_COMMAND))
{
if (!class_exists('AntiVir')) {
require_once DOL_DOCUMENT_ROOT.'/core/class/antivir.class.php';
}
- $antivir = new AntiVir($db);
+ $antivir=new AntiVir($db);
$result = $antivir->dol_avscan_file($src_file);
if ($result < 0) // If virus or error, we stop here
{
- $reterrors = $antivir->errors;
+ $reterrors=$antivir->errors;
return $reterrors;
}
}
@@ -1853,6 +1853,7 @@ function dol_convert_file($fileinput, $ext = 'png', $fileoutput = '', $page = ''
if (empty($fileoutput)) $fileoutput = $fileinput.".".$ext;
$count = $image->getNumberImages();
+
if (!dol_is_file($fileoutput) || is_writeable($fileoutput))
{
try {
diff --git a/htdocs/core/lib/sendings.lib.php b/htdocs/core/lib/sendings.lib.php
index 34dd845cdfa..ad1e6304d03 100644
--- a/htdocs/core/lib/sendings.lib.php
+++ b/htdocs/core/lib/sendings.lib.php
@@ -415,7 +415,7 @@ function show_list_sending_receive($origin, $origin_id, $filter = '')
//var_dump($expedition->linkedObjects);
$receiving = '';
- if (count($expedition->linkedObjects['delivery']) > 0) $receiving = reset($expedition->linkedObjects['delivery']); // Take first link
+ if (!empty($expedition->linkedObjects['delivery'])) $receiving = reset($expedition->linkedObjects['delivery']); // Take first link
if (!empty($receiving))
{