Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 0b26860

Browse files
committed
Clean up cpluspluscheck violation.
"typename" is a C++ keyword, so pg_upgrade.h fails to compile in C++. Fortunately, there seems no likely reason for somebody to need to do that. Nonetheless, it's project policy that all .h files should pass cpluspluscheck, so rename the argument to fix that. Oversight in 57c081d; back-patch as that was. (The policy requiring pg_upgrade.h to pass cpluspluscheck only goes back to v12, but it seems best to keep this code looking the same in all branches.)
1 parent 898c629 commit 0b26860

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/bin/pg_upgrade/pg_upgrade.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -455,7 +455,7 @@ bool check_for_data_types_usage(ClusterInfo *cluster,
455455
const char *base_query,
456456
const char *output_path);
457457
bool check_for_data_type_usage(ClusterInfo *cluster,
458-
const char *typename,
458+
const char *type_name,
459459
const char *output_path);
460460
void new_9_0_populate_pg_largeobject_metadata(ClusterInfo *cluster,
461461
bool check_mode);

src/bin/pg_upgrade/version.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -236,20 +236,20 @@ check_for_data_types_usage(ClusterInfo *cluster,
236236
*
237237
* If so, write a report to the given file name, and return true.
238238
*
239-
* typename should be a fully qualified type name. This is just a
239+
* type_name should be a fully qualified type name. This is just a
240240
* trivial wrapper around check_for_data_types_usage() to convert a
241241
* type name into a base query.
242242
*/
243243
bool
244244
check_for_data_type_usage(ClusterInfo *cluster,
245-
const char *typename,
245+
const char *type_name,
246246
const char *output_path)
247247
{
248248
bool found;
249249
char *base_query;
250250

251251
base_query = psprintf("SELECT '%s'::pg_catalog.regtype AS oid",
252-
typename);
252+
type_name);
253253

254254
found = check_for_data_types_usage(cluster, base_query, output_path);
255255

0 commit comments

Comments
 (0)