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

Appearance settings

Commit 6844d32

Browse filesBrowse files
committed
Remove useless if condition
We can call GetAttributeCompression() with a NULL argument. It handles that internally already. This change makes all the callers of GetAttributeCompression() uniform. Reviewed-by: Alvaro Herrera <alvherre@alvh.no-ip.org> Discussion: https://www.postgresql.org/message-id/flat/52a125e4-ff9a-95f5-9f61-b87cf447e4da@eisentraut.org
1 parent 689c66a commit 6844d32
Copy full SHA for 6844d32

File tree

Expand file treeCollapse file tree

1 file changed

+1
-5
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-5
lines changed

‎src/backend/commands/tablecmds.c

Copy file name to clipboardExpand all lines: src/backend/commands/tablecmds.c
+1-5Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -944,11 +944,7 @@ DefineRelation(CreateStmt *stmt, char relkind, Oid ownerId,
944944

945945
attr->attidentity = colDef->identity;
946946
attr->attgenerated = colDef->generated;
947-
948-
if (colDef->compression)
949-
attr->attcompression = GetAttributeCompression(attr->atttypid,
950-
colDef->compression);
951-
947+
attr->attcompression = GetAttributeCompression(attr->atttypid, colDef->compression);
952948
if (colDef->storage_name)
953949
attr->attstorage = GetAttributeStorage(attr->atttypid, colDef->storage_name);
954950
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.