Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit7cac630

Browse files
committed
Fix compiler warning in mul_var_short().
Some compilers (e.g., gcc before version 7) mistakenly think "carry"might be used uninitialized.Reported by Tom Lane, per various buildfarm members, e.g. arowana.
1 parent8daa62a commit7cac630

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

‎src/backend/utils/adt/numeric.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8969,7 +8969,7 @@ mul_var_short(const NumericVar *var1, const NumericVar *var2,
89698969
intres_ndigits;
89708970
NumericDigit*res_buf;
89718971
NumericDigit*res_digits;
8972-
uint32carry;
8972+
uint32carry=0;
89738973
uint32term;
89748974

89758975
/* Check preconditions */
@@ -9018,7 +9018,6 @@ mul_var_short(const NumericVar *var1, const NumericVar *var2,
90189018
*res_ndigits = var2ndigits + 1
90199019
* ----------
90209020
*/
9021-
carry=0;
90229021
for (inti=var2ndigits-1;i >=0;i--)
90239022
{
90249023
term=PRODSUM1(var1digits,0,var2digits,i)+carry;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp