Changeset bb9ec2d in mainline for uspace/lib/c/generic/elf/elf_load.c


Ignore:
Timestamp:
2017-03-07T20:47:35Z (8 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
a737667e
Parents:
e796dc8
git-author:
Jiri Zarevucky <zarevucky.jiri@…> (2017-03-07 20:47:35)
git-committer:
Jakub Jermar <jakub@…> (2017-03-07 20:47:35)
Message:

Merge from lp:~zarevucky-jiri/helenos/vfs-2.5/ revision 1941-1944

Original commit messages:

1944: Jiri Zarevucky 2013-08-06 Replace legacy file descriptor presetting with inbox.
1943: Jiri Zarevucky 2013-08-06 Do not preserve open state when passing file descriptor to another task. Allow receiver to specify, whether the descriptor is low or high.
1942: Jiri Zarevucky 2013-08-06 C style.
1941: Jiri Zarevucky 2013-08-06 Make loader accept file reference instead of a pathname.

Modifications:

  • Keep version of elf_load_file() that accepts file name
  • Changes required for loading dynamically linked executables
  • Update to newer list_foreach
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/elf/elf_load.c

    re796dc8 rbb9ec2d  
    4141#include <stdio.h>
    4242#include <stdlib.h>
     43#include <vfs/vfs.h>
    4344
    4445#ifdef CONFIG_RTLD
     
    5051/** Load ELF program.
    5152 *
    52  * @param file_name File name
     53 * @param file File handle
    5354 * @param info Place to store ELF program information
    5455 * @return EOK on success or non-zero error code
    5556 */
    56 int elf_load(const char *file_name, elf_info_t *info)
     57int elf_load(int file, elf_info_t *info)
    5758{
    5859#ifdef CONFIG_RTLD
     
    6162        int rc;
    6263
    63         rc = elf_load_file(file_name, 0, 0, &info->finfo);
     64        rc = elf_load_file(file, 0, 0, &info->finfo);
    6465        if (rc != EE_OK) {
    6566                DPRINTF("Failed to load executable '%s'.\n", file_name);
Note: See TracChangeset for help on using the changeset viewer.