]> granicus.if.org Git - php/commitdiff
Happy new year (especially to Zeev :)
authorThies C. Arntzen <thies@php.net>
Sat, 1 Jan 2000 16:52:14 +0000 (16:52 +0000)
committerThies C. Arntzen <thies@php.net>
Sat, 1 Jan 2000 16:52:14 +0000 (16:52 +0000)
ext/mysql/php_mysql.c

index fa5277b10527690023c94fe3fe1eccba33d1918e..02e68f638af3726e66baab85f1bbd66afe0d989e 100644 (file)
@@ -1247,6 +1247,8 @@ PHP_FUNCTION(mysql_result)
                }
        }
 
+       return_value->type = IS_STRING;
+
        if (sql_row[field_offset]) {
                if (PG(magic_quotes_runtime)) {
                        return_value->value.str.val = php_addslashes(sql_row[field_offset],sql_row_lengths[field_offset],&return_value->value.str.len,0);
@@ -1257,8 +1259,6 @@ PHP_FUNCTION(mysql_result)
        } else {
                return_value->type = IS_UNSET;
        }
-       
-       return_value->type = IS_STRING;
 }
 /* }}} */