You are here

function clamav_get_version in ClamAV 6

Same name and namespace in other branches
  1. 7 clamav.inc \clamav_get_version()

Get the version information for clamav.

Parameters

Mixed $settings For executable:: String: path to the clamscan executable For daemon: Array: providing the keys 'host' and 'port'

Return value

String The version string, as provided by clamav.

2 calls to clamav_get_version()
clamav_admin_settings in ./clamav.admin.inc
Admin settings page for ClamAV
clamav_requirements in ./clamav.install
Implementation of hook_requirements().

File

./clamav.inc, line 204
API and helper functions for the ClamAV module.

Code

function clamav_get_version($settings) {
  if (is_string($settings) && !empty($settings)) {
    return _clamav_get_version_via_exec($settings);
  }
  elseif (is_array($settings) && isset($settings['host']) && isset($settings['port'])) {
    return _clamav_get_version_via_daemon($settings['host'], $settings['port']);
  }
}