mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-19 21:57:55 +00:00
app/usb_webcam: initialize libc environment
Restores debugging with LIBUSB_DEBUG=<level>.
This commit is contained in:
parent
f324aa902b
commit
bfce470690
@ -19,6 +19,7 @@
|
|||||||
#include <base/log.h>
|
#include <base/log.h>
|
||||||
#include <gui_session/connection.h>
|
#include <gui_session/connection.h>
|
||||||
#include <libc/component.h>
|
#include <libc/component.h>
|
||||||
|
#include <libc/args.h>
|
||||||
#include <os/pixel_rgb888.h>
|
#include <os/pixel_rgb888.h>
|
||||||
|
|
||||||
#pragma GCC diagnostic push
|
#pragma GCC diagnostic push
|
||||||
@ -295,7 +296,17 @@ class Main
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
extern char **environ;
|
||||||
|
|
||||||
void Libc::Component::construct(Libc::Env &env)
|
void Libc::Component::construct(Libc::Env &env)
|
||||||
{
|
{
|
||||||
|
int argc = 0;
|
||||||
|
char **argv = nullptr;
|
||||||
|
char **envp = nullptr;
|
||||||
|
|
||||||
|
populate_args_and_env(env, argc, argv, envp);
|
||||||
|
|
||||||
|
environ = envp;
|
||||||
|
|
||||||
static Main main(env);
|
static Main main(env);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user