@@ -26,17 +26,17 @@ |
||
26 | 26 | |
27 | 27 | // used by distribution lists |
28 | 28 | define("DL_GUID", pack("H*", "C091ADD3519DCF11A4A900AA0047FAA4")); |
29 | - define("DL_USER", 0xC3); // 195 |
|
30 | - define("DL_USER2", 0xD3); // 211 |
|
31 | - define("DL_USER3", 0xE3); // 227 |
|
29 | + define("DL_USER", 0xC3); // 195 |
|
30 | + define("DL_USER2", 0xD3); // 211 |
|
31 | + define("DL_USER3", 0xE3); // 227 |
|
32 | 32 | /* |
33 | 33 | * According to Exchange protocol, type property for oneoff contact |
34 | 34 | * will be 0x00. |
35 | 35 | */ |
36 | - define("DL_EXTERNAL_MEMBER", 0x00); // 0 |
|
37 | - define("DL_DIST", 0xB4); // 180 |
|
38 | - define("DL_USER_AB", 0xB5); // 181 |
|
39 | - define("DL_DIST_AB", 0xB6); // 182 |
|
36 | + define("DL_EXTERNAL_MEMBER", 0x00); // 0 |
|
37 | + define("DL_DIST", 0xB4); // 180 |
|
38 | + define("DL_USER_AB", 0xB5); // 181 |
|
39 | + define("DL_DIST_AB", 0xB6); // 182 |
|
40 | 40 | |
41 | 41 | // @FIXME these needs to be changed in mapitags.php |
42 | 42 |
@@ -23,8 +23,7 @@ |
||
23 | 23 | |
24 | 24 | # Replicate value logic from php-src/ext/zlib/zlib.c |
25 | 25 | $sv = ini_get("zlib.output_compression"); |
26 | - $sv = strcasecmp($sv, "on") == 0 ? 1 : |
|
27 | - (strcasecmp($sv, "off") == 0 ? 0 : intval($sv)); |
|
26 | + $sv = strcasecmp($sv, "on") == 0 ? 1 : (strcasecmp($sv, "off") == 0 ? 0 : intval($sv)); |
|
28 | 27 | if ($sv != 0) { |
29 | 28 | $this->error_config("zlib.output_compression", "off", "With this option enabled, it could occur that XMLHTTP requests will fail"); |
30 | 29 | } |
@@ -389,7 +389,7 @@ discard block |
||
389 | 389 | if ($data_orig_strs[$i]['length'] > 0) { // fread does not accept length=0 |
390 | 390 | $length = $data_orig_strs[$i]['length']; |
391 | 391 | $orig_str = unpack('a' . $length . 'str', fread($fp, $length)); |
392 | - $translation_data[$i]['msgid'] = $orig_str['str']; // unpack converts to array :S |
|
392 | + $translation_data[$i]['msgid'] = $orig_str['str']; // unpack converts to array :S |
|
393 | 393 | |
394 | 394 | // Find context in the original string |
395 | 395 | if (strpos($translation_data[$i]['msgid'], "\004") !== false) { |
@@ -416,7 +416,7 @@ discard block |
||
416 | 416 | if ($data_transl_strs[$i]['length'] > 0) { // fread does not accept length=0 |
417 | 417 | $length = $data_transl_strs[$i]['length']; |
418 | 418 | $trans_str = unpack('a' . $length . 'str', fread($fp, $length)); |
419 | - $translation_data[$i]['msgstr'] = $trans_str['str']; // unpack converts to array :S |
|
419 | + $translation_data[$i]['msgstr'] = $trans_str['str']; // unpack converts to array :S |
|
420 | 420 | |
421 | 421 | // If there are plural forms in the source string, |
422 | 422 | // then the translated string must contain plural |
@@ -55,13 +55,13 @@ discard block |
||
55 | 55 | $entryId = strtoupper($entryid); |
56 | 56 | |
57 | 57 | $res = [ |
58 | - 'abFlags' => '', // BYTE[4], 4 bytes, 8 hex characters |
|
59 | - 'guid' => '', // GUID, 16 bytes, 32 hex characters |
|
60 | - 'version' => '', // ULONG, 4 bytes, 8 hex characters |
|
61 | - 'type' => '', // ULONG, 4 bytes, 8 hex characters |
|
62 | - 'uniqueId' => '', // ULONG, 16 bytes, 32 hex characters |
|
63 | - 'server' => '', // CHAR, variable length |
|
64 | - 'padding' => '', // TCHAR[3], 4 bytes, 8 hex characters (upto 4 bytes) |
|
58 | + 'abFlags' => '', // BYTE[4], 4 bytes, 8 hex characters |
|
59 | + 'guid' => '', // GUID, 16 bytes, 32 hex characters |
|
60 | + 'version' => '', // ULONG, 4 bytes, 8 hex characters |
|
61 | + 'type' => '', // ULONG, 4 bytes, 8 hex characters |
|
62 | + 'uniqueId' => '', // ULONG, 16 bytes, 32 hex characters |
|
63 | + 'server' => '', // CHAR, variable length |
|
64 | + 'padding' => '', // TCHAR[3], 4 bytes, 8 hex characters (upto 4 bytes) |
|
65 | 65 | ]; |
66 | 66 | |
67 | 67 | $res['length'] = strlen($entryId); |
@@ -100,13 +100,13 @@ discard block |
||
100 | 100 | $entryId = strtoupper($entryid); |
101 | 101 | |
102 | 102 | $res = [ |
103 | - 'abFlags' => '', // BYTE[4], 4 bytes, 8 hex characters |
|
104 | - 'guid' => '', // GUID, 16 bytes, 32 hex characters |
|
105 | - 'version' => '', // ULONG, 4 bytes, 8 hex characters |
|
106 | - 'type' => '', // ULONG, 4 bytes, 8 hex characters |
|
107 | - 'id' => '', // ULONG, 4 bytes, 8 hex characters |
|
108 | - 'server' => '', // CHAR, variable length |
|
109 | - 'padding' => '', // TCHAR[3], 4 bytes, 8 hex characters (upto 4 bytes) |
|
103 | + 'abFlags' => '', // BYTE[4], 4 bytes, 8 hex characters |
|
104 | + 'guid' => '', // GUID, 16 bytes, 32 hex characters |
|
105 | + 'version' => '', // ULONG, 4 bytes, 8 hex characters |
|
106 | + 'type' => '', // ULONG, 4 bytes, 8 hex characters |
|
107 | + 'id' => '', // ULONG, 4 bytes, 8 hex characters |
|
108 | + 'server' => '', // CHAR, variable length |
|
109 | + 'padding' => '', // TCHAR[3], 4 bytes, 8 hex characters (upto 4 bytes) |
|
110 | 110 | ]; |
111 | 111 | |
112 | 112 | $res['length'] = strlen($entryId); |
@@ -185,13 +185,13 @@ discard block |
||
185 | 185 | $entryId = strtoupper($entryId); |
186 | 186 | |
187 | 187 | $res = [ |
188 | - 'abFlags' => '', // BYTE[4], 4 bytes, 8 hex characters |
|
189 | - 'guid' => '', // GUID, 16 bytes, 32 hex characters |
|
190 | - 'version' => '', // ULONG, 4 bytes, 8 hex characters |
|
191 | - 'type' => '', // ULONG, 4 bytes, 8 hex characters |
|
192 | - 'id' => '', // ULONG, 16 bytes, 32 hex characters |
|
193 | - 'extid' => '', // CHAR, variable length |
|
194 | - 'padding' => '', // TCHAR[3], 4 bytes, 8 hex characters (upto 4 bytes) |
|
188 | + 'abFlags' => '', // BYTE[4], 4 bytes, 8 hex characters |
|
189 | + 'guid' => '', // GUID, 16 bytes, 32 hex characters |
|
190 | + 'version' => '', // ULONG, 4 bytes, 8 hex characters |
|
191 | + 'type' => '', // ULONG, 4 bytes, 8 hex characters |
|
192 | + 'id' => '', // ULONG, 16 bytes, 32 hex characters |
|
193 | + 'extid' => '', // CHAR, variable length |
|
194 | + 'padding' => '', // TCHAR[3], 4 bytes, 8 hex characters (upto 4 bytes) |
|
195 | 195 | ]; |
196 | 196 | |
197 | 197 | $res['length'] = strlen($entryId); |
@@ -636,8 +636,7 @@ discard block |
||
636 | 636 | } |
637 | 637 | } |
638 | 638 | elseif ($checkValue !== null && $val != $checkValue) { |
639 | - $user = $GLOBALS["mapisession"] !== null ? $GLOBALS["mapisession"]->getUserName() : |
|
640 | - "<mapisession not yet initialized>"; |
|
639 | + $user = $GLOBALS["mapisession"] !== null ? $GLOBALS["mapisession"]->getUserName() : "<mapisession not yet initialized>"; |
|
641 | 640 | error_log(sprintf( |
642 | 641 | "Unexpected value in store entryid for user %s. Entryid: %s key: '%s' value: '%s' expected: %s", |
643 | 642 | $user, |
@@ -667,13 +666,13 @@ discard block |
||
667 | 666 | $entryId = strtoupper($entryId); |
668 | 667 | |
669 | 668 | $res = [ |
670 | - 'providerguid' => '', // GUID, 16 bytes, 32 hex characters |
|
671 | - 'messagetype' => '', // UINT, 2 bytes, 4 hex characters |
|
672 | - 'folderdbguid' => '', // GUID, 16 bytes, 32 hex characters |
|
673 | - 'foldercounter' => '', // ULONG, 6 bytes, 12 hex characters |
|
674 | - 'padding' => '', // TCHAR[3], 2 bytes, 4 hex characters |
|
675 | - 'messagedbguid' => '', // GUID, 16 bytes, 32 hex characters |
|
676 | - 'messagecounter' => '', // ULONG, 6 bytes, 12 hex characters |
|
669 | + 'providerguid' => '', // GUID, 16 bytes, 32 hex characters |
|
670 | + 'messagetype' => '', // UINT, 2 bytes, 4 hex characters |
|
671 | + 'folderdbguid' => '', // GUID, 16 bytes, 32 hex characters |
|
672 | + 'foldercounter' => '', // ULONG, 6 bytes, 12 hex characters |
|
673 | + 'padding' => '', // TCHAR[3], 2 bytes, 4 hex characters |
|
674 | + 'messagedbguid' => '', // GUID, 16 bytes, 32 hex characters |
|
675 | + 'messagecounter' => '', // ULONG, 6 bytes, 12 hex characters |
|
677 | 676 | ]; |
678 | 677 | |
679 | 678 | if (!$entryId) { |
@@ -733,12 +732,12 @@ discard block |
||
733 | 732 | $entryId = strtoupper($entryId); |
734 | 733 | |
735 | 734 | $res = [ |
736 | - 'abflags' => '', // BYTE[4], 4 bytes, 8 hex characters |
|
737 | - 'providerguid' => '', // GUID, 16 bytes, 32 hex characters |
|
738 | - 'foldertype' => '', // UINT, 2 bytes, 4 hex characters |
|
739 | - 'folderdbguid' => '', // GUID, 16 bytes, 32 hex characters |
|
740 | - 'foldercounter' => '', // ULONG, 6 bytes, 12 hex characters |
|
741 | - 'padding' => '', // TCHAR[3], 2 bytes, 4 hex characters |
|
735 | + 'abflags' => '', // BYTE[4], 4 bytes, 8 hex characters |
|
736 | + 'providerguid' => '', // GUID, 16 bytes, 32 hex characters |
|
737 | + 'foldertype' => '', // UINT, 2 bytes, 4 hex characters |
|
738 | + 'folderdbguid' => '', // GUID, 16 bytes, 32 hex characters |
|
739 | + 'foldercounter' => '', // ULONG, 6 bytes, 12 hex characters |
|
740 | + 'padding' => '', // TCHAR[3], 2 bytes, 4 hex characters |
|
742 | 741 | ]; |
743 | 742 | |
744 | 743 | if (!$entryId) { |
@@ -217,7 +217,7 @@ discard block |
||
217 | 217 | // OR |
218 | 218 | [RES_OR, |
219 | 219 | [ |
220 | - [RES_AND, // Normal items: itemEnd must be after viewStart, itemStart must be before viewEnd |
|
220 | + [RES_AND, // Normal items: itemEnd must be after viewStart, itemStart must be before viewEnd |
|
221 | 221 | [ |
222 | 222 | [RES_PROPERTY, |
223 | 223 | [RELOP => RELOP_GT, |
@@ -241,7 +241,7 @@ discard block |
||
241 | 241 | ], |
242 | 242 | ], |
243 | 243 | ], // EXISTS OR |
244 | - ]; // global OR |
|
244 | + ]; // global OR |
|
245 | 245 | |
246 | 246 | // Get requested properties, plus whatever we need |
247 | 247 | $proplist = [PR_ENTRYID, $properties["recurring"], $properties["recurring_data"], $properties["timezone_data"]]; |
@@ -360,7 +360,7 @@ |
||
360 | 360 | ]; |
361 | 361 | $fileDependencies[$filename] = [ |
362 | 362 | 'depends' => [], |
363 | - 'core' => $core, // Based on tag or on class or on file path? |
|
363 | + 'core' => $core, // Based on tag or on class or on file path? |
|
364 | 364 | ]; |
365 | 365 | |
366 | 366 | for ($j = 0, $lenJ = count($class[1]); $j < $lenJ; ++$j) { |
@@ -58,8 +58,8 @@ |
||
58 | 58 | curl_setopt($curl, CURLOPT_USERPWD, $this->userName . ":" . $this->password); |
59 | 59 | curl_setopt($curl, CURLOPT_FILE, $file_handle); |
60 | 60 | curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true); |
61 | - curl_setopt($curl, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS); |
|
62 | - curl_setopt($curl, CURLOPT_REDIR_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS); |
|
61 | + curl_setopt($curl, CURLOPT_PROTOCOLS, CURLPROTO_HTTP|CURLPROTO_HTTPS); |
|
62 | + curl_setopt($curl, CURLOPT_REDIR_PROTOCOLS, CURLPROTO_HTTP|CURLPROTO_HTTPS); |
|
63 | 63 | |
64 | 64 | curl_exec($curl); |
65 | 65 |
@@ -10,7 +10,7 @@ |
||
10 | 10 | * @return Number the event which this module handles |
11 | 11 | */ |
12 | 12 | public function getEvents() { |
13 | - return OBJECT_DELETE | OBJECT_SAVE; |
|
13 | + return OBJECT_DELETE|OBJECT_SAVE; |
|
14 | 14 | } |
15 | 15 | |
16 | 16 | /** |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | if ($stateFolder) { |
36 | 36 | $store = $GLOBALS["mapisession"]->getDefaultMessageStore(); |
37 | 37 | $username = $GLOBALS["mapisession"]->getUserName(); |
38 | - $hierarchyTable = mapi_folder_gethierarchytable($stateFolder, CONVENIENT_DEPTH | MAPI_DEFERRED_ERRORS); |
|
38 | + $hierarchyTable = mapi_folder_gethierarchytable($stateFolder, CONVENIENT_DEPTH|MAPI_DEFERRED_ERRORS); |
|
39 | 39 | $rows = mapi_table_queryallrows($hierarchyTable, [PR_ENTRYID, PR_DISPLAY_NAME]); |
40 | 40 | foreach ($rows as $row) { |
41 | 41 | $deviceStateFolder = mapi_msgstore_openentry($store, $row[PR_ENTRYID]); |
@@ -897,7 +897,7 @@ discard block |
||
897 | 897 | if (!$this->stateFolder) { |
898 | 898 | $store = $GLOBALS["mapisession"]->getDefaultMessageStore(); |
899 | 899 | $rootFolder = mapi_msgstore_openentry($store); |
900 | - $hierarchy = mapi_folder_gethierarchytable($rootFolder, CONVENIENT_DEPTH | MAPI_DEFERRED_ERRORS); |
|
900 | + $hierarchy = mapi_folder_gethierarchytable($rootFolder, CONVENIENT_DEPTH|MAPI_DEFERRED_ERRORS); |
|
901 | 901 | $restriction = $this->getStateFolderRestriction(PLUGIN_MDM_STORE_STATE_FOLDER); |
902 | 902 | mapi_table_restrict($hierarchy, $restriction); |
903 | 903 | if (mapi_table_getrowcount($hierarchy) == 1) { |