RDK Documentation (Open Sourced RDK Components)
Crashupload Public APIs

Description

Functions

static void process_interrupt_handler (const int s)
 Signal Handler function. More...
 
static int directory_watcher (const char *const directory, const char *command_to_run, const char *command_args, const char *const *const patterns, const size_t pattern_count)
 This API notifies whether dump is generated in the minidump directory and triggers the upload dump script to upload the files to server. More...
 
int main (const int argc, const char *const *const argv)
 Main Function. More...
 

Function Documentation

◆ process_interrupt_handler()

static void process_interrupt_handler ( const int  s)
static

Signal Handler function.

Parameters
[in]sSignal Type

Definition at line 74 of file inotify-minidump-watcher.c.

◆ directory_watcher()

static int directory_watcher ( const char *const  directory,
const char *  command_to_run,
const char *  command_args,
const char *const *const  patterns,
const size_t  pattern_count 
)
static

This API notifies whether dump is generated in the minidump directory and triggers the upload dump script to upload the files to server.

Parameters
[in]directoryDirectory name
[in]command_to_runShell script to execute
[in]command_argsArguments for shell script
[in]patternsPattern to verify, Patterns can be *.dmp, *.cmd etc.
[in]pattern_countNumber of patterns to be verified.

Definition at line 92 of file inotify-minidump-watcher.c.

◆ main()

int main ( const int  argc,
const char *const *const  argv 
)

Main Function.

This binary is used to monitor the specified directory in the box and when there is a change, corresponding upload script will kick in and uploads the files to the server.

Usage: /usr/bin/inotify-minidump-watcher DIRECTORY COMMAND_TO_RUN COMMAND_ARGS PATTERN Eg: /usr/bin/inotify-minidump-watcher /minidumps /lib/rdk/uploadDumps.sh "" 0 *.dmp

Definition at line 225 of file inotify-minidump-watcher.c.