aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor
diff options
context:
space:
mode:
authorPeter Eisentraut <peter@eisentraut.org>2022-12-30 10:02:59 +0100
committerPeter Eisentraut <peter@eisentraut.org>2022-12-30 10:12:24 +0100
commit5f2f99c9c62d754c19e090cb57fdd929438ea519 (patch)
treed53db6531735a581bf660a0e7ed1d5cfd7bae31b /src/backend/executor
parent388e80132c007a7528abc987e347e41432dc1542 (diff)
downloadpostgresql-5f2f99c9c62d754c19e090cb57fdd929438ea519.tar.gz
postgresql-5f2f99c9c62d754c19e090cb57fdd929438ea519.zip
Remove unnecessary casts
Some code carefully cast all data buffer arguments for data write and read function calls to void *, even though the respective arguments are already void *. Remove this unnecessary clutter. Discussion: https://www.postgresql.org/message-id/flat/11dda853-bb5b-59ba-a746-e168b1ce4bdb%40enterprisedb.com
Diffstat (limited to 'src/backend/executor')
-rw-r--r--src/backend/executor/nodeAgg.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/executor/nodeAgg.c b/src/backend/executor/nodeAgg.c
index 30c91431838..f15bb83a1ac 100644
--- a/src/backend/executor/nodeAgg.c
+++ b/src/backend/executor/nodeAgg.c
@@ -2961,10 +2961,10 @@ hashagg_spill_tuple(AggState *aggstate, HashAggSpill *spill,
tape = spill->partitions[partition];
- LogicalTapeWrite(tape, (void *) &hash, sizeof(uint32));
+ LogicalTapeWrite(tape, &hash, sizeof(uint32));
total_written += sizeof(uint32);
- LogicalTapeWrite(tape, (void *) tuple, tuple->t_len);
+ LogicalTapeWrite(tape, tuple, tuple->t_len);
total_written += tuple->t_len;
if (shouldFree)
@@ -3029,7 +3029,7 @@ hashagg_batch_read(HashAggBatch *batch, uint32 *hashp)
tuple->t_len = t_len;
nread = LogicalTapeRead(tape,
- (void *) ((char *) tuple + sizeof(uint32)),
+ (char *) tuple + sizeof(uint32),
t_len - sizeof(uint32));
if (nread != t_len - sizeof(uint32))
ereport(ERROR,