forked from bersler/OpenLogReplicator
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathOpCode1A06.cpp
More file actions
74 lines (57 loc) · 2.91 KB
/
Copy pathOpCode1A06.cpp
File metadata and controls
74 lines (57 loc) · 2.91 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
/* Oracle Redo OpCode: 26.6
Copyright (C) 2018-2024 Adam Leszczynski ([email protected])
This file is part of OpenLogReplicator.
OpenLogReplicator is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as published
by the Free Software Foundation; either version 3, or (at your option)
any later version.
OpenLogReplicator is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
Public License for more details.
You should have received a copy of the GNU General Public License
along with OpenLogReplicator; see the file LICENSE; If not see
<http://www.gnu.org/licenses/>. */
#include "../common/RedoLogRecord.h"
#include "OpCode1A06.h"
namespace OpenLogReplicator {
void OpCode1A06::process1A06(Ctx* ctx, RedoLogRecord* redoLogRecord) {
uint64_t fieldPos = 0;
typeField fieldNum = 0;
uint16_t fieldLength = 0;
RedoLogRecord::nextField(ctx, redoLogRecord, fieldNum, fieldPos, fieldLength, 0x1A0601);
// Field: 1
if (fieldLength < 12)
throw RedoLogException(50061, "too short field 26.6.1: " + std::to_string(fieldLength) + " offset: " +
std::to_string(redoLogRecord->dataOffset));
RedoLogRecord::nextField(ctx, redoLogRecord, fieldNum, fieldPos, fieldLength, 0x1A0602);
// Field: 2
if (fieldLength < 32)
throw RedoLogException(50061, "too short field 26.6.2: " + std::to_string(fieldLength) + " offset: " +
std::to_string(redoLogRecord->dataOffset));
redoLogRecord->recordDataObj = ctx->read32(redoLogRecord->data + fieldPos + 24);
OpCode::process(ctx, redoLogRecord);
fieldPos = 0;
fieldNum = 0;
fieldLength = 0;
RedoLogRecord::nextField(ctx, redoLogRecord, fieldNum, fieldPos, fieldLength, 0x1A0603);
// Field: 1
kdliCommon(ctx, redoLogRecord, fieldPos, fieldLength);
RedoLogRecord::nextField(ctx, redoLogRecord, fieldNum, fieldPos, fieldLength, 0x1A0604);
// Field: 2
kdli(ctx, redoLogRecord, fieldPos, fieldLength);
RedoLogRecord::nextField(ctx, redoLogRecord, fieldNum, fieldPos, fieldLength, 0x1A0605);
// Field: 3
kdli(ctx, redoLogRecord, fieldPos, fieldLength);
if (!RedoLogRecord::nextFieldOpt(ctx, redoLogRecord, fieldNum, fieldPos, fieldLength, 0x1A0606))
return;
// Field: 4
if (redoLogRecord->opc == KDLI_OP_BIMG) {
kdliDataLoad(ctx, redoLogRecord, fieldPos, fieldLength);
if (!RedoLogRecord::nextFieldOpt(ctx, redoLogRecord, fieldNum, fieldPos, fieldLength, 0x1A0607))
return;
}
// Field: 4/5 - suplog?
kdli(ctx, redoLogRecord, fieldPos, fieldLength);
}
}