diff --git a/ecrire/inc/headers.php b/ecrire/inc/headers.php
index dd6bf5674d9e25bafdef9068d13484b2d313f0b8..5ae8f932bba86de4cb3c2c922404fcda624279ad 100644
--- a/ecrire/inc/headers.php
+++ b/ecrire/inc/headers.php
@@ -46,7 +46,7 @@ function redirige_par_entete($url, $equiv='', $status = 302) {
 
 	// Il n'y a que sous Apache que setcookie puis redirection fonctionne
   include_spip('inc/cookie');
-	if (!$equiv AND (!spip_cookie_envoye() OR (strncmp("Apache", $_SERVER['SERVER_SOFTWARE'],6)==0) OR defined('_SERVER_APACHE'))) {
+	if ((!$equiv AND !spip_cookie_envoye()) OR ((strncmp("Apache", $_SERVER['SERVER_SOFTWARE'],6)==0) OR defined('_SERVER_APACHE'))) {
 		@header("Location: " . $url);
 		$equiv="";
 	} else {