Age | Commit message (Collapse) | Author |
|
* exec.c (prepare_stream): New function, broken out of prepare.
(prepare): Call it.
[_STDIO_USES_IOSTREAM]: Do #error if this is defined.
(map, input_room, close_exec_stream, fake_seek, prepare_stream):
Conditionalize all these definitions on [! _STDIO_USES_IOSTREAM].
Only map and prepare_stream are called from elsewhere in the code.
(check_gzip): Don't reinitialize E->stream, since it will in fact not
be used again.
(check_bzip2): Likewise.
|
|
* exec.c (servercopy): Removed unused variable.
|
|
* exec.c (load_section): Fix typos in last change.
|
|
* exec.c (load_section): Use mmap instead of vm_allocate when
allocating in mach_task_self ().
(servercopy): Likewise.
(do_exec): Likewise.
* hashexec.c (check_hashbang): Likewise.
|
|
* exec.c (check_elf): Call elf_machine_matches_host instead of
comparing against elf_machine.
(load_section): #if 0 out no-op code that uses elf_machine.
* priv.h (elf_machine_matches_host): Declare it.
(elf_machine, mach_host_elf_machine): Remove decls.
* main.c (main) [!BFD]: Don't call mach_host_elf_machine.
(elf_machine): Variable removed.
* exec.c (map): Don't cast arg to munmap to vm_address_t.
|
|
* core.c (core_dump_task): Use munmap instead of vm_deallocate,
when it's from our own task.
* elfcore.c: Likewise.
* exec.c (load_section): Likewise.
(map): Likewise.
(close_exec_stream): Likewise.
(finish_mapping): Likewise.
(load): Likewise.
(do_exec): Likewise.
(S_exec_setexecdata): Likewise.
* hashexec.c (check_hashbang): Likewise.
* main.c (deadboot): Likewise.
|
|
* exec.c (map): Fix mapping calls to use F->__offset consistently
instead of F->__target.
|
|
* do-bunzip2.c: New file.
* exec.c (check_bzip2): New function.
(BZIP2): New cpp symbol. If defined, bunzip2 engine is enabled.
* Makefile (bzip2-objects): New variable.
(OBJS): Add bzip2-objects.
(CPPFLAGS): Add -DBZIP2.
|
|
* exec.c (do_exec): Implement EXEC_SIGTRAP flag.
|
|
* exec.c (do_exec): Fix conditional for cleaning up INTERP,
from nonnull E.interp.section to nonnull INTERP.file.
If we failed to open the interpreter file, INTERP.file will be
null and the rest of INTERP will be uninitialized.
|
|
* exec.c (do_exec): Set boot->phdr_addr and boot->user_entry after
loading, to addresses adjusted for actual run-time load address.
|
|
* exec.c (load_section): If ANYWHERE, then make sure ADDR starts
out at least past the first page, so that we don't take it. Then
the library can (if desired) make the page no-access.
Fri Nov 15 17:34:23 1996 Thomas Bushnell, n/BSG <thomas@gnu.ai.mit.edu>
* exec.c: Don't include <hurd/shared.h> any more.
* main.c (S_exec_init): New arg syntax of trivfs_open.
|
|
* exec.c (fake_seek): New function.
(prepare): Initialize E->stream.__io_funcs.seek to fake_seek; this
is called now that stdio doesn't assume it always knows the file
position.
|
|
exec_exec stub.
|
|
more loosely.
|
|
|
|
otherwise it modifies the stub process's state and not the real
process's.
|
|
|
|
|
|
|
|
|
|
|
|
Request round_page (LEN) bytes in io_read to avoid many small reads.
|
|
and deallocating its address space.
|
|
because that's what they are; also because some callers of read_error
don't set errno at all.
|
|
|
|
If io_map returns EOPNOTSUPP, suppress the error, and still setup E's stream.
(prepare_and_check):
If prepare returns an error, do no more.
|
|
Use strdupa().
Update use of hurd_file_name_lookup() [still probably not right though].
|
|
|
|
|
|
Be careful not to look at BOOT after we release our reference on it.
Correctly initialize BOOT->intarray in the case where NINTS < INIT_INT_MAX
but we don't alloc a new array.
|
|
(input_room): Simplify.
(check_elf): Extract all information from file header before calling `map'
for program headers.
|
|
(load_section): Call it.
|
|
|
|
|
|
|
|
|
|
(S_exec_startup): Just call it.
|
|
(std_*, finish): Make global.
(do_exec): Only reset CWDIR when null, even if secure.
Actually call check_hashbang and return success if it does.
Use new hurd_file_name_lookup protocol with private callbacks to open
interpreter file on behalf of client.
Remove `bootout' label; use `stdout' or `out' as appropriate instead.
At `out' label always deref BOOT, which cleans it up iff necessary.
(S_exec_exec): #if 0 out $EXECSERVERS processing for time being.
|
|
Main program split out into main.c.
(std_lock): New variable (rwlock).
(do_exec): Acquire reader lock to access std_ints and std_ports.
(S_exec_setexecdata): Acquire writer lock to change them.
|
|
|
|
completely with OLDTASK.
(do_mach_notify_no_senders): Remove bogus mod_refs call on receive_portset.
|
|
(do_exec): Set them. Code rearranged to construct bootinfo before looking
up interpreter file, keep proper track of port rights and VM copied into
bootinfo (there were leaks).
|
|
|
|
(map): Likewise.
(prepare): Likewise.
(load): Likewise.
(servercopy): Likewise.
(do_exec): Likewise.
(S_exec_setexecdata): Likewise.
(S_exec_exec): Put extra parens around assignment inside while
test.
|
|
(load_section): Use them; if `anywhere' set, load the section anywhere.
Record load address in `loadbase'.
(check_elf): Initialize `anywhere' and `loadbase'.
(postload): Merged into load.
(load): Perform postload functionality here, after calling finish_mapping.
(finish): Take new flag arg; deallocate file port only if set.
(do_exec): Pass flag to finish appropriately.
Don't call finish_mapping and postload after load.
KLUDGE: Load the interpreter before the program instead of after.
|
|
Secondarily uses the BFD library #ifdef BFD.
Supports gunzipping only #ifdef GZIP.
|
|
|
|
Open a new BFD on the uncompressed data stream before return.
|
|
(check_section): Notice section named ".interp" and set that pointer.
(load_section): Do nothing if the section is zero size.
When reading into our copy of the overlap page, don't read past the end of
the section.
(do_exec): Consolidate new subfunction `check_maybe_gzip'.
If there is an interpreter section, load the interpreter file too,
and use its entry point instead of the user program's.
Cleaned up and made more robust deallocation of BOOT info on error.
(deadboot): New function, split out of do_mach_port_notify_no_senders.
|