From d7e0e61d847d929dd3df67ecf16519beca990d69 Mon Sep 17 00:00:00 2001
From: "Thomas G. Lockhart" <lockhart@fourpalms.org>
Date: Thu, 4 Dec 1997 23:28:20 +0000
Subject: [PATCH] Run through toupper() conversion in the forward direction. 
 Most processors should optimize this a bit better wrt cache prefetch.

---
 src/interfaces/libpq/fe-exec.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/interfaces/libpq/fe-exec.c b/src/interfaces/libpq/fe-exec.c
index 72752ad36bd..d9609ee3285 100644
--- a/src/interfaces/libpq/fe-exec.c
+++ b/src/interfaces/libpq/fe-exec.c
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *	  $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-exec.c,v 1.42 1997/12/01 22:02:49 momjian Exp $
+ *	  $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-exec.c,v 1.43 1997/12/04 23:28:20 thomas Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -1697,7 +1697,7 @@ PQfnumber(PGresult *res, const char *field_name)
 		*(field_case + strlen(field_case) - 1) = '\0';
 	}
 	else
-		for (i = strlen(field_case); i >= 0; i--)
+		for (i = 0; i < strlen(field_case); i++)
 			if (isupper(field_case[i]))
 				field_case[i] = tolower(field_case[i]);
 
-- 
GitLab