]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
Unpickler.load_inst(), Unpickler.load_obj(), Unpickler.load_build():
authorBarry Warsaw <barry@python.org>
Mon, 26 Jan 1998 22:47:35 +0000 (22:47 +0000)
committerBarry Warsaw <barry@python.org>
Mon, 26 Jan 1998 22:47:35 +0000 (22:47 +0000)
commitabe2a457de09d728ddd0704fc1de855adf263944
treea6319828e132f7bf3598915f526cabffcc930c26
parent5da0f504baa10c6125b5c7cc6dccc801f26f5ff0
Unpickler.load_inst(), Unpickler.load_obj(), Unpickler.load_build():
Fixed problems when unpickling in restricted execution environments.
These methods try to assign to an instance's __class__ attribute, or
access the instances __dict__, which are prohibited in REE.  For the
first two methods, I re-implemented the old behavior when assignment
to value.__class__ fails.

For the load_build() I also re-implemented the old behavior when
inst.__dict__.update() fails but this means that unpickling in REE is
semantically different than unpickling in unrestricted mode.
Lib/pickle.py