summaryrefslogtreecommitdiff
path: root/main/main.c
diff options
context:
space:
mode:
authorSVN Migration <svn@php.net>1999-07-23 14:14:44 +0000
committerSVN Migration <svn@php.net>1999-07-23 14:14:44 +0000
commit5cb21cbfef2dcdf31ac914920427d3d190c6ed26 (patch)
treea6ea5826ba1eda810e9580a335798c020dfaeb9a /main/main.c
parentb1617d8ac3bad1ace92085194e24cff8cbdbaf31 (diff)
downloadphp-git-php-4.0b1.tar.gz
This commit was manufactured by cvs2svn to create tag 'php_4_0b1'.php-4.0b1
Diffstat (limited to 'main/main.c')
-rw-r--r--main/main.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/main/main.c b/main/main.c
index 59d1a54b37..6e801350d0 100644
--- a/main/main.c
+++ b/main/main.c
@@ -426,20 +426,18 @@ PHPAPI void php3_error(int type, const char *format,...)
}
}
if (PG(track_errors)) {
- pval *tmp;
+ pval tmp;
va_start(args, format);
size = vsnprintf(buffer, sizeof(buffer) - 1, format, args);
va_end(args);
buffer[sizeof(buffer) - 1] = 0;
- tmp = (pval *)emalloc(sizeof(pval));
- INIT_PZVAL(tmp);
- tmp->value.str.val = (char *) estrndup(buffer, size);
- tmp->value.str.len = size;
- tmp->type = IS_STRING;
+ tmp.value.str.val = (char *) estrndup(buffer, size);
+ tmp.value.str.len = size;
+ tmp.type = IS_STRING;
- _php3_hash_update(EG(active_symbol_table), "php_errormsg", sizeof("php_errormsg"), (void **) & tmp, sizeof(pval *), NULL);
+ _php3_hash_update(EG(active_symbol_table), "php_errormsg", sizeof("php_errormsg"), (void *) & tmp, sizeof(pval), NULL);
}
switch (type) {