This repository has been archived by the owner on Jan 22, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Require program account to be writable in extend program data ix #27911
Merged
jstarry
merged 2 commits into
solana-labs:master
from
jstarry:feat/write-program-in-extend
Sep 22, 2022
Merged
Require program account to be writable in extend program data ix #27911
jstarry
merged 2 commits into
solana-labs:master
from
jstarry:feat/write-program-in-extend
Sep 22, 2022
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jstarry
added
the
feature-gate
Pull Request adds or modifies a runtime feature gate
label
Sep 19, 2022
jstarry
force-pushed
the
feat/write-program-in-extend
branch
4 times, most recently
from
September 19, 2022 14:47
06fd7f3
to
8cf6288
Compare
jstarry
force-pushed
the
feat/write-program-in-extend
branch
from
September 20, 2022 00:39
8cf6288
to
1c2a7de
Compare
Lichtso
reviewed
Sep 20, 2022
ic_logger_msg!(log_collector, "Invalid Program account"); | ||
return Err(InstructionError::InvalidAccountData); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we move drop(program_account);
here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that's more clear. Moved.
Lichtso
previously approved these changes
Sep 20, 2022
mergify
bot
dismissed
Lichtso’s stale review
September 21, 2022 07:58
Pull request has been modified.
automerge label removed due to a CI failure |
mergify
bot
removed
the
automerge
Merge this Pull Request automatically once CI passes
label
Sep 21, 2022
mergify bot
pushed a commit
that referenced
this pull request
Sep 22, 2022
) * Require program account to be writable in extend program data ix * feedback (cherry picked from commit 108b245) # Conflicts: # programs/bpf_loader/src/lib.rs # sdk/program/src/bpf_loader_upgradeable.rs # sdk/program/src/loader_upgradeable_instruction.rs # sdk/src/feature_set.rs # transaction-status/src/parse_bpf_loader.rs
mergify bot
pushed a commit
that referenced
this pull request
Sep 22, 2022
) * Require program account to be writable in extend program data ix * feedback (cherry picked from commit 108b245) # Conflicts: # programs/bpf_loader/src/lib.rs # sdk/program/src/bpf_loader_upgradeable.rs # sdk/program/src/loader_upgradeable_instruction.rs # sdk/src/feature_set.rs # transaction-status/src/parse_bpf_loader.rs
This was referenced Sep 22, 2022
mergify bot
pushed a commit
that referenced
this pull request
Sep 22, 2022
) * Require program account to be writable in extend program data ix * feedback (cherry picked from commit 108b245) # Conflicts: # programs/bpf_loader/src/lib.rs
mergify bot
added a commit
that referenced
this pull request
Sep 22, 2022
…kport #27911) (#27978) * Require program account to be writable in extend program data ix (#27911) * Require program account to be writable in extend program data ix * feedback (cherry picked from commit 108b245) # Conflicts: # programs/bpf_loader/src/lib.rs * fix conflicts Co-authored-by: Justin Starry <[email protected]>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Problem
The
ExtendProgramData
instruction doesn't write lock the program account and so the runtime can be sure of the size of a program's data account when loading a program for a transaction. This presented an issue when restricting the total account data size of a transaction in #27840Summary of Changes
ExtendProgramData
toExtendProgram
now that this instruction operates on the program account itself tooExtendProgram
instruction and require it to be writableModifies Feature Gate: #26385