Advertisement
Guest User

ZBX-4302

a guest
Mar 30th, 2012
159
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 8.08 KB | None | 0 0
  1. --- ./src/libs/zbxserver/expression.c.orig  2012-03-30 14:55:53.136539389 +0200
  2. +++ ./src/libs/zbxserver/expression.c   2012-03-30 14:52:37.516538689 +0200
  3. @@ -465,7 +465,7 @@
  4.     const char  *__function_name = "DCexpand_trigger_expression";
  5.  
  6.     char        *tmp = NULL;
  7. -   size_t      tmp_alloc = 256, tmp_offset = 0, l, r;
  8. +   size_t      tmp_alloc = 1025, tmp_offset = 0, l, r;
  9.     DC_FUNCTION function;
  10.     DC_ITEM     item;
  11.     zbx_uint64_t    functionid;
  12.  
  13. --- frontends/php/include/schema.inc.php.orig   2012-03-30 14:38:32.096541376 +0200
  14. +++ frontends/php/include/schema.inc.php    2012-03-30 14:38:08.566537692 +0200
  15. @@ -2191,13 +2191,13 @@
  16.             'expression' => array(
  17.                 'null' => false,
  18.                 'type' => DB::FIELD_TYPE_CHAR,
  19. -               'length' => 255,
  20. +               'length' => 1024,
  21.                 'default' => '',
  22.             ),
  23.             'description' => array(
  24.                 'null' => false,
  25.                 'type' => DB::FIELD_TYPE_CHAR,
  26. -               'length' => 255,
  27. +               'length' => 1024,
  28.                 'default' => '',
  29.             ),
  30.             'url' => array(
  31. @@ -3682,7 +3682,7 @@
  32.             'expression' => array(
  33.                 'null' => false,
  34.                 'type' => DB::FIELD_TYPE_CHAR,
  35. -               'length' => 255,
  36. +               'length' => 1024,
  37.                 'default' => '',
  38.             ),
  39.             'expression_type' => array(
  40.  
  41. --- ./database/mysql/schema.sql.orig    2012-03-30 14:40:13.626523795 +0200
  42. +++ ./database/mysql/schema.sql 2012-03-30 14:40:57.176529646 +0200
  43. @@ -470,8 +470,8 @@
  44.  ) ENGINE=InnoDB;
  45.  CREATE TABLE triggers (
  46.     triggerid                bigint unsigned                           NOT NULL,
  47. -   expression               varchar(255)    DEFAULT ''                NOT NULL,
  48. -   description              varchar(255)    DEFAULT ''                NOT NULL,
  49. +   expression               varchar(1024)    DEFAULT ''               NOT NULL,
  50. +   description              varchar(1024)    DEFAULT ''               NOT NULL,
  51.     url                      varchar(255)    DEFAULT ''                NOT NULL,
  52.     status                   integer         DEFAULT '0'               NOT NULL,
  53.     value                    integer         DEFAULT '0'               NOT NULL,
  54. @@ -816,7 +816,7 @@
  55.  CREATE TABLE expressions (
  56.     expressionid             bigint unsigned                           NOT NULL,
  57.     regexpid                 bigint unsigned                           NOT NULL,
  58. -   expression               varchar(255)    DEFAULT ''                NOT NULL,
  59. +   expression               varchar(1024)    DEFAULT ''               NOT NULL,
  60.     expression_type          integer         DEFAULT '0'               NOT NULL,
  61.     exp_delimiter            varchar(1)      DEFAULT ''                NOT NULL,
  62.     case_sensitive           integer         DEFAULT '0'               NOT NULL,
  63.  
  64. --- ./src/libs/zbxdbhigh/dbschema.c.orig    2012-03-30 14:45:46.616467523 +0200
  65. +++ ./src/libs/zbxdbhigh/dbschema.c 2012-03-30 14:48:11.696540533 +0200
  66. @@ -537,8 +537,8 @@
  67.     {"triggers",    "triggerid",    ZBX_SYNC,
  68.         {
  69.         {"triggerid",   NULL,   NULL,   0,  ZBX_TYPE_ID,    ZBX_NOTNULL,    0},
  70. -       {"expression",  NULL,   NULL,   255,    ZBX_TYPE_CHAR,  ZBX_NOTNULL | ZBX_SYNC, 0},
  71. -       {"description", NULL,   NULL,   255,    ZBX_TYPE_CHAR,  ZBX_NOTNULL | ZBX_SYNC, 0},
  72. +       {"expression",  NULL,   NULL,   1024,   ZBX_TYPE_CHAR,  ZBX_NOTNULL | ZBX_SYNC, 0},
  73. +       {"description", NULL,   NULL,   1024,   ZBX_TYPE_CHAR,  ZBX_NOTNULL | ZBX_SYNC, 0},
  74.         {"url", NULL,   NULL,   255,    ZBX_TYPE_CHAR,  ZBX_NOTNULL | ZBX_SYNC, 0},
  75.         {"status",  NULL,   NULL,   0,  ZBX_TYPE_INT,   ZBX_NOTNULL | ZBX_SYNC, 0},
  76.         {"value",   NULL,   NULL,   0,  ZBX_TYPE_INT,   ZBX_NOTNULL | ZBX_SYNC, 0},
  77. @@ -919,7 +919,7 @@
  78.         {
  79.         {"expressionid",    NULL,   NULL,   0,  ZBX_TYPE_ID,    ZBX_NOTNULL,    0},
  80.         {"regexpid",    "regexps",  "regexpid", 0,  ZBX_TYPE_ID,    ZBX_NOTNULL | ZBX_SYNC | ZBX_PROXY, ZBX_FK_CASCADE_DELETE},
  81. -       {"expression",  NULL,   NULL,   255,    ZBX_TYPE_CHAR,  ZBX_NOTNULL | ZBX_SYNC | ZBX_PROXY, 0},
  82. +       {"expression",  NULL,   NULL,   1024,   ZBX_TYPE_CHAR,  ZBX_NOTNULL | ZBX_SYNC | ZBX_PROXY, 0},
  83.         {"expression_type", NULL,   NULL,   0,  ZBX_TYPE_INT,   ZBX_NOTNULL | ZBX_SYNC | ZBX_PROXY, 0},
  84.         {"exp_delimiter",   NULL,   NULL,   1,  ZBX_TYPE_CHAR,  ZBX_NOTNULL | ZBX_SYNC | ZBX_PROXY, 0},
  85.         {"case_sensitive",  NULL,   NULL,   0,  ZBX_TYPE_INT,   ZBX_NOTNULL | ZBX_SYNC | ZBX_PROXY, 0},
  86. @@ -1889,8 +1889,8 @@
  87.  );\n\
  88.  CREATE TABLE triggers (\n\
  89.  triggerid bigint  NOT NULL,\n\
  90. -expression varchar(255) WITH DEFAULT '' NOT NULL,\n\
  91. -description varchar(255) WITH DEFAULT '' NOT NULL,\n\
  92. +expression varchar(1024) WITH DEFAULT '' NOT NULL,\n\
  93. +description varchar(1024) WITH DEFAULT '' NOT NULL,\n\
  94.  url varchar(255) WITH DEFAULT '' NOT NULL,\n\
  95.  status integer WITH DEFAULT '0' NOT NULL,\n\
  96.  value integer WITH DEFAULT '0' NOT NULL,\n\
  97. @@ -2235,7 +2235,7 @@
  98.  CREATE TABLE expressions (\n\
  99.  expressionid bigint  NOT NULL,\n\
  100.  regexpid bigint  NOT NULL,\n\
  101. -expression varchar(255) WITH DEFAULT '' NOT NULL,\n\
  102. +expression varchar(1024) WITH DEFAULT '' NOT NULL,\n\
  103.  expression_type integer WITH DEFAULT '0' NOT NULL,\n\
  104.  exp_delimiter varchar(1) WITH DEFAULT '' NOT NULL,\n\
  105.  case_sensitive integer WITH DEFAULT '0' NOT NULL,\n\
  106. @@ -3411,8 +3411,8 @@
  107.  ) ENGINE=InnoDB;\n\
  108.  CREATE TABLE triggers (\n\
  109.  triggerid bigint unsigned  NOT NULL,\n\
  110. -expression varchar(255) DEFAULT '' NOT NULL,\n\
  111. -description varchar(255) DEFAULT '' NOT NULL,\n\
  112. +expression varchar(1024) DEFAULT '' NOT NULL,\n\
  113. +description varchar(1024) DEFAULT '' NOT NULL,\n\
  114.  url varchar(255) DEFAULT '' NOT NULL,\n\
  115.  status integer DEFAULT '0' NOT NULL,\n\
  116.  value integer DEFAULT '0' NOT NULL,\n\
  117. @@ -3757,7 +3757,7 @@
  118.  CREATE TABLE expressions (\n\
  119.  expressionid bigint unsigned  NOT NULL,\n\
  120.  regexpid bigint unsigned  NOT NULL,\n\
  121. -expression varchar(255) DEFAULT '' NOT NULL,\n\
  122. +expression varchar(1024) DEFAULT '' NOT NULL,\n\
  123.  expression_type integer DEFAULT '0' NOT NULL,\n\
  124.  exp_delimiter varchar(1) DEFAULT '' NOT NULL,\n\
  125.  case_sensitive integer DEFAULT '0' NOT NULL,\n\
  126. @@ -4933,8 +4933,8 @@
  127.  );\n\
  128.  CREATE TABLE triggers (\n\
  129.  triggerid number(20)  NOT NULL,\n\
  130. -expression nvarchar2(255) DEFAULT '' ,\n\
  131. -description nvarchar2(255) DEFAULT '' ,\n\
  132. +expression nvarchar2(1024) DEFAULT '' ,\n\
  133. +description nvarchar2(1024) DEFAULT '' ,\n\
  134.  url nvarchar2(255) DEFAULT '' ,\n\
  135.  status number(10) DEFAULT '0' NOT NULL,\n\
  136.  value number(10) DEFAULT '0' NOT NULL,\n\
  137. @@ -5279,7 +5279,7 @@
  138.  CREATE TABLE expressions (\n\
  139.  expressionid number(20)  NOT NULL,\n\
  140.  regexpid number(20)  NOT NULL,\n\
  141. -expression nvarchar2(255) DEFAULT '' ,\n\
  142. +expression nvarchar2(1024) DEFAULT '' ,\n\
  143.  expression_type number(10) DEFAULT '0' NOT NULL,\n\
  144.  exp_delimiter nvarchar2(1) DEFAULT '' ,\n\
  145.  case_sensitive number(10) DEFAULT '0' NOT NULL,\n\
  146. @@ -6527,8 +6527,8 @@
  147.  );\n\
  148.  CREATE TABLE triggers (\n\
  149.  triggerid bigint  NOT NULL,\n\
  150. -expression varchar(255) DEFAULT '' NOT NULL,\n\
  151. -description varchar(255) DEFAULT '' NOT NULL,\n\
  152. +expression varchar(1024) DEFAULT '' NOT NULL,\n\
  153. +description varchar(1024) DEFAULT '' NOT NULL,\n\
  154.  url varchar(255) DEFAULT '' NOT NULL,\n\
  155.  status integer DEFAULT '0' NOT NULL,\n\
  156.  value integer DEFAULT '0' NOT NULL,\n\
  157. @@ -6873,7 +6873,7 @@
  158.  CREATE TABLE expressions (\n\
  159.  expressionid bigint  NOT NULL,\n\
  160.  regexpid bigint  NOT NULL,\n\
  161. -expression varchar(255) DEFAULT '' NOT NULL,\n\
  162. +expression varchar(1024) DEFAULT '' NOT NULL,\n\
  163.  expression_type integer DEFAULT '0' NOT NULL,\n\
  164.  exp_delimiter varchar(1) DEFAULT '' NOT NULL,\n\
  165.  case_sensitive integer DEFAULT '0' NOT NULL,\n\
  166. @@ -8049,8 +8049,8 @@
  167.  );\n\
  168.  CREATE TABLE triggers (\n\
  169.  triggerid bigint  NOT NULL,\n\
  170. -expression varchar(255) DEFAULT '' NOT NULL,\n\
  171. -description varchar(255) DEFAULT '' NOT NULL,\n\
  172. +expression varchar(1024) DEFAULT '' NOT NULL,\n\
  173. +description varchar(1024) DEFAULT '' NOT NULL,\n\
  174.  url varchar(255) DEFAULT '' NOT NULL,\n\
  175.  status integer DEFAULT '0' NOT NULL,\n\
  176.  value integer DEFAULT '0' NOT NULL,\n\
  177. @@ -8395,7 +8395,7 @@
  178.  CREATE TABLE expressions (\n\
  179.  expressionid bigint  NOT NULL,\n\
  180.  regexpid bigint  NOT NULL REFERENCES regexps (regexpid) ON DELETE CASCADE,\n\
  181. -expression varchar(255) DEFAULT '' NOT NULL,\n\
  182. +expression varchar(1024) DEFAULT '' NOT NULL,\n\
  183.  expression_type integer DEFAULT '0' NOT NULL,\n\
  184.  exp_delimiter varchar(1) DEFAULT '' NOT NULL,\n\
  185.  case_sensitive integer DEFAULT '0' NOT NULL,\n\
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement