Cross reference for modules/ud/ud_main.c of index.

# File modules/ud/ud_main.c

      $Revision: 1.19 $

      Wrapper for NRTM client

      Status: NOT REVUED, NOT TESTED

     Author(s):       Andrei Robachevsky

## Included Files

- `#include <sys/types.h>`

- `#include <sys/socket.h>`

- `#include <netinet/in.h>`

- `#include <arpa/inet.h>`

- `#include <fcntl.h>`

- `#include <signal.h>`

- `#include "modules/ud/ud.h"`

- `#include "modules/ud/ud_int.h"`
  - `#include <stdio.h>`
  - `#include <strings.h>`
  - `#include <glib.h>`
  - `#include <stdlib.h>`
  - `#include <ctype.h>`
  - `#include <unistd.h>`
  - `#include "include/defs.h"`
    - `#include <glib.h>`
    - `#include "include/bitmask.h"`
    - `#include "include/DF_class_enum.def"`
    - `#include "include/DF_class_mask.def"`
    - `#include "include/DF_attribute_enum.def"`
    - `#include "include/DF_attribute_inv_attr_mask.def"`
    - `#include "include/which_keytypes.h"`
      - `#include "include/bitmask.h"`
    - `#include "include/iproutines.h"`
      - `#include <glib.h>`
      - `#include <include/erroutines.h>`
      - `#include <sys/types.h>`
    - `#include "include/rxroutines.h"`
      - `#include <glib.h>`
      - `#include <pthread.h>`
      - `#include <stubs.h>`
      - `#include <include/memwrap.h>`
      - `#include <stdio.h>`
      - `#include <iproutines.h>`
      - `#include <erroutines.h>`
      - `#include "include/socket.h"`
        - `#include <sys/types.h>`
        - `#include <sys/socket.h>`
        - `#include <netinet/in.h>`
        - `#include <stdlib.h>`
        - `#include <errno.h>`
        - `#include <netdb.h>`
        - `#include <signal.h>`
        - `#include <stdio.h>`
        - `#include <iproutines.h>`
      - `#include "include/thread.h"`
        - `#include <pthread.h>`
  - `#include "include/mysql_driver.h"`
    - `#include "/opt/package/mysql/include/mysql/mysql.h"`
      - `#include <sys/types.h>`
      - `#include "/opt/package/mysql/include/mysql/mysql_com.h"`
      - `#include "/opt/package/mysql/include/mysql/mysql_version.h"`
    - `#include "/opt/package/mysql/include/mysql/mysqld_error.h"`
  - `#include "include/iproutines.h"`
  - `#include "include/rp.h"`
    - `#include <stddef.h>`
    - `#include <glib.h>`
    - `#include <defs.h>`
    - `#include <iproutines.h>`
    - `#include <erroutines.h>`
    - `#include <rxroutines.h>`
    - `#include <mysql_driver.h>`
    - `#include "include/ca_defs.h"`
      - `#include <pthread.h>`
      - `#include <glib.h>`
  - `#include "include/nh.h"`
    - `#include <mysql_driver.h>`
  - `#include "include/ca_configFns.h"`
    - `#include "include/ca_defs.h"`
  - `#include "include/ca_dictSyms.h"`
  - `#include "include/ca_macros.h"`
    - `#include "include/ca_adminAttribs.h"`
  - `#include "include/ca_srcAttribs.h"`
  - `#include "include/globaldefs.h"`
  - `#include "include/bitmask.h"`
  - `#include "include/which_keytypes.h"`

- `#include "include/constants.h"`
  - `#include <glib.h>`

- `#include "include/server.h"`

- `#include "include/protocol_mirror.h"`
  - `#include <glib.h>`
  - `#include "include/mysql_driver.h"`
  - `#include "include/iproutines.h"`

- `#include "include/ta.h"`
  - `#include <glib.h>`
  - `#include <pthread.h>`
  - `#include <stubs.h>`
  - `#include <memwrap.h>`
  - `#include <stdio.h>`
  - `#include <include/socket.h>`
  - `#include <include/timediff.h>`

## Preprocessor definitions

`#define TIMEOUT 60`

`#define SBUNCH 1000`

## Global Variable Lock

`pthread_mutex_t Lock`

Included from | include/ca_defs.h
Visible in: |  | modules/ac/access_control.c
|  | modules/ca/ca_configFns.c
|  | modules/ca/ca_values.c
|  | modules/pm/pm_serials.c
|  | modules/pm/protocol_mirror.c
|  | modules/qc/query_command.c
|  | modules/qi/query_instructions.c
|  | modules/rp/rp_convert.c
|  | modules/rp/rp_load.c
|  | modules/rp/rp_search.c
|  | modules/rp/rp_tree.c
|  | modules/rp/rp_update.c
|  | modules/sv/server.c
|  | modules/ud/ud_comrol.c
|  | modules/ud/ud_core.c
|  | modules/ud/ud_main.c
Used in: | ca_get_adminIntElement() | modules/ca/ca_configFns.c
| ca_get_adminStrElement() | modules/ca/ca_configFns.c
| ca_get_boolean() | modules/ca/ca_configFns.c
| ca_get_dirlist() | modules/ca/ca_configFns.c
| ca_get_int() | modules/ca/ca_configFns.c
| ca_get_string() | modules/ca/ca_configFns.c
| ca_set_boolean() | modules/ca/ca_configFns.c
| ca_set_string() | modules/ca/ca_configFns.c

## Global Variable newPort

`char newPort[16]`

Included from | include/ca_defs.h
Visible in: |  | modules/ac/access_control.c
|  | modules/ca/ca_configFns.c
|  | modules/ca/ca_values.c
|  | modules/pm/pm_serials.c
|  | modules/pm/protocol_mirror.c
|  | modules/qc/query_command.c
|  | modules/qi/query_instructions.c
|  | modules/rp/rp_convert.c
|  | modules/rp/rp_load.c
|  | modules/rp/rp_search.c
|  | modules/rp/rp_tree.c
|  | modules/rp/rp_update.c
|  | modules/sv/server.c
|  | modules/ud/ud_comrol.c
|  | modules/ud/ud_core.c
|  | modules/ud/ud_main.c

## External Variables

SV_update_sock
`extern int SV_update_sock[]`

Defined in: | modules/sv/server.c

## Global Function UD_do_nrtm()

     main cycle

`void UD_do_nrtm ( void* arg )`

Prototyped in: | modules/ud/ud.h
Calls: | CO_get_do_server() | modules/co/constants.c
| CO_get_do_update() | modules/co/constants.c
| PM_get_minmax_serial() | modules/pm/pm_serials.c
| SQ_close_connection() | modules/sq/mysql_driver.c
| SQ_get_connection() | modules/sq/mysql_driver.c
| SV_sleep() | modules/sv/server.c
| TA_add() | modules/ta/ta.c
| TA_delete() | modules/ta/ta.c
| TA_setactivity() | modules/ta/ta.c
| ca_get_SourceHandleByPosition() | modules/ca/ca_configFns.c
| ca_srchandle2Intelement() | modules/ca/ca_configFns.c
| ca_srchandle2Strelement() | modules/ca/ca_configFns.c
| get_NRTM_fd() | modules/ud/ud_main.c
| UD_process_stream(), calloc(), fclose(), fdopen(), fflush(), fopen(), fprintf(), free(), mysql_ping(), printf(), sleep(), sprintf()
Used in: | SV_start() | modules/sv/server.c

## Global Function UD_do_updates()

     main cycle

`void UD_do_updates ( void* arg )`

Prototyped in: | modules/ud/ud.h
Calls: | CO_get_do_server() | modules/co/constants.c
| CO_get_do_update() | modules/co/constants.c
| SK_accept_connection() | modules/sk/sk_socket.c
| SQ_close_connection() | modules/sq/mysql_driver.c
| SQ_get_connection() | modules/sq/mysql_driver.c
| TA_add() | modules/ta/ta.c
| TA_delete() | modules/ta/ta.c
| TA_setactivity() | modules/ta/ta.c
| ca_get_SourceHandleByPosition() | modules/ca/ca_configFns.c
| ca_srchandle2Intelement() | modules/ca/ca_configFns.c
| ca_srchandle2Strelement() | modules/ca/ca_configFns.c
| UD_process_stream(), fclose(), fdopen(), fflush(), fopen(), fprintf(), free(), mysql_ping()
Used in: | SV_start() | modules/sv/server.c
References Variables: | SV_update_sock | modules/sv/server.c

## Global Function get_NRTM_fd()

`int get_NRTM_fd ( struct _nrtm* nrtm, int upto_last, char* source )`

Prototyped in: | modules/ud/ud_int.h
Calls: | SK_write() | modules/sk/sk_socket.c
| bzero(), close(), connect(), fprintf(), gethostbyname_r(), inet_ntoa(), memcpy(), open(), perror(), socket(), sprintf(), strlen()
Called by: | UD_do_nrtm() | modules/ud/ud_main.c