summaryrefslogtreecommitdiff
path: root/int_array.c
diff options
context:
space:
mode:
authorAndrew J. Schorr <aschorr@telemetry-investments.com>2016-06-30 09:59:47 -0400
committerAndrew J. Schorr <aschorr@telemetry-investments.com>2016-06-30 09:59:47 -0400
commit92b5353bf364897f02003c4116cabe6d48ea17eb (patch)
tree3a942f5608c3065f49fa175ef688316e04daacc9 /int_array.c
parent2ab2d5f2c468b647615d984cb7953217c63695af (diff)
downloadgawk-92b5353bf364897f02003c4116cabe6d48ea17eb.tar.gz
Use new STFMT_UNUSED define to improve code clarity, and fix some minor stfmt issues.
Diffstat (limited to 'int_array.c')
-rw-r--r--int_array.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/int_array.c b/int_array.c
index f17bddef..e7913dea 100644
--- a/int_array.c
+++ b/int_array.c
@@ -92,8 +92,10 @@ is_integer(NODE *symbol, NODE *subs)
/*
* Protect against MAYBE_NUM values where the string may not regenerate
* correctly. There could be white space and/or a non-decimal value.
+ * If stfmt is not STFMT_UNUSED, it means that the string value was
+ * generated using CONVFMT or OFMT, so there is no info there.
*/
- if ((subs->flags & STRCUR) != 0) {
+ if ((subs->flags & STRCUR) != 0 && subs->stfmt == STFMT_UNUSED) {
char *cp = subs->stptr;
if ( subs->stlen == 0