aboutsummaryrefslogtreecommitdiffstats
path: root/tests/test8.c
blob: aa7debdba90d65c1aa48ed34574c328e69f9fd32 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
/* test posix thread folder proxy */


#include "camel.h"

CamelThreadProxy *proxy;
CamelFuncDef *func_def;


void 
test_sync_func (int num)
{
    printf ("Sync function number %d\n", num);
    printf ("Sync function : current thread : %d\n", pthread_self ());
  
}


void 
test_async_cb (int num)
{
    printf ("Callback number %d\n", num);   
    printf ("Callback : current thread : %d\n", pthread_self ());
}

void 
test_async_func (int num)
{
  CamelOp *cb;

  printf ("Async function number %d\n", num);
  printf ("Async function : current thread : %d\n", pthread_self ());
  sleep (1);    
  cb = camel_marshal_create_op (func_def, test_async_cb, num);
  camel_thread_proxy_push_cb (proxy, cb);
  
    
}

int 
main (int argc, char **argv)
{
    int i;
    CamelOp *op;

    camel_init ();

    func_def = 
      camel_func_def_new (camel_marshal_NONE__INT, 
                  1, 
                  GTK_TYPE_INT);

    printf ("--== Testing Simple marshalling system ==--\n");
    for (i=0; i<5; i++) {
      printf ("Iterration number %d\n", i);
      op = camel_marshal_create_op (func_def, test_sync_func, i);
      camel_op_run (op);
      camel_op_free (op);

    }           
    printf ("\n\n");

    proxy = camel_thread_proxy_new ();

    printf ("--== Testing Asynchronous Operation System ==--\n");
    for (i=0; i<5; i++) {
      printf ("Pushing async operation number %d for execution\n", i);
      op = camel_marshal_create_op (func_def, test_async_func, i);
      camel_thread_proxy_push_op (proxy, op);
    }           
    printf ("\n\n");
    printf ("--== Operations execution planned ==--\n");
    gtk_main ();
} 

98a3d68aa333009962'>net-mgmt/check_ssl_cert: update to 2.2.0Christoph Moench-Tegeder2021-05-082-4/+4 * net-mgmt/zabbix5-server: Update to 5.0.11Pakhom Golynga2021-05-072-4/+4 * net-mgmt/cacti-spine: Update to 1.2.17Steven Kreuzer2021-05-072-4/+4 * net-mgmt/check_ssl_cert: update to 2.1.4Christoph Moench-Tegeder2021-05-072-4/+4 * net-mgmt/mbrowse: reduce overlinking and remove pkg depBaptiste Daroussin2021-05-062-6/+14 * Deorbit RESTRICTED && NO_CDROM, part one.Mathieu Arnold2021-05-061-3/+1 * net-mgmt/check_ssl_cert: update to 2.1.3Christoph Moench-Tegeder2021-05-062-7/+4 * - Update two VictoriaMetrics ports to version 1.59.0Alexey Dokuchaev2021-05-055-45/+53 * net-mgmt/py-arouteserver: Update version 0.26.0=>1.5.1Muhammad Moinur Rahman2021-05-052-8/+4 * net-mgmt/bgpq4: Update version 0.0.6=>0.0.7Muhammad Moinur Rahman2021-05-052-4/+4 * net-mgmt/centreon-clib: Update version 20.10.0=>21.04.0Muhammad Moinur Rahman2021-05-054-11/+23 * net-mgmt/icingaweb2-module-grafana: Update to 1.4.2Lars Engels2021-05-042-4/+4 * net-mgmt/tcpreplay: Update to 4.3.4Emanuel Haupt2021-05-022-17/+15 * net-mgmt/icingaweb2-module-cube: Update to 1.1.1Lars Engels2021-05-023-5/+6 * net-mgmt/icingaweb2-module-grafana: Update to 1.4.1Lars Engels2021-05-022-5/+4 * net-mgmt/virt-viewer: Add missing USES=perl5 and unbreakTobias Kortkamp2021-05-021-7/+3 * net-mgmt/check_ups_health: update 2.9.2.4 -> 2.9.2.7Kurt Jaeger2021-05-012-4/+4 * net-mgmt/check_ssl_cert: update to 2.1.2Christoph Moench-Tegeder2021-05-012-5/+8 * net-mgmt/icingaweb2-module-fileshipper: Update distinfoTrond Endrestol2021-04-301-3/+3 * net-mgmt/check_ssl_cert: update to 2.1.1Christoph Moench-Tegeder2021-04-302-4/+4 * net-mgmt/check_ssl_cert: update to 2.1.0Christoph Moench-Tegeder2021-04-292-4/+4 * net-mgmt/wmi-client: backport three fixes to nbtsocket.c from upstreamAlexey Dokuchaev2021-04-292-4/+84 * Install a newsyslog config file to rotate Librenms logs.Dan Langille2021-04-293-0/+20 * New port: net-mgmt/py-opn-cli: OPNsense CLI written in PythonNeel Chauhan2021-04-294-0/+31 * net-mgmt/virt-viewer: add missing pod2man build dependencyRoman Bogorodskiy2021-04-281-0/+1 * net-mgmt/icingaweb2-module-fileshipper: Update to 1.2.0Lars Engels2021-04-281-2/+1 * Update to 21.4.0Dan Langille2021-04-276-66/+7 * *: Updated to 8.0.4Richard Gallamore2021-04-262-5/+5 * Update `net-mgmt/wifimgr' to version 1.14, which brings:Alexey Dokuchaev2021-04-253-8/+23 * net-mgmt/virt-viewer: update to 10.0Roman Bogorodskiy2021-04-254-122/+85 * net-mgmt/pmacct: Use opt_LIB_DEPENDSTobias Kortkamp2021-04-241-6/+6 * net-mgmt/pmacct: Unbreak build with --enable-option-checking=fatalTobias Kortkamp2021-04-241-8/+2 * net-mgmt/networkmgr: update to 5.0Eric Turgeon2021-04-233-4/+6 * *: Garbage collect new $FreeBSD ids.Mathieu Arnold2021-04-201-3/+0 * net-mgmt/unifi-poller: update to 2.1.3Neel Chauhan2021-04-202-43/+43 * net-mgmt/py-prometheus-client: Update to 0.10.1Luca Pizzamiglio2021-04-192-4/+4 * net-mgmt/netbox: Update to 2.10.10Kai Knoblich2021-04-183-4/+5 * net-mgmt/py-adal: Update to 1.2.7Po-Chuan Hsieh2021-04-182-5/+5 * net-mgmt/p5-Xymon-Server: Cosmetic changePo-Chuan Hsieh2021-04-181-2/+3 * net-mgmt/p5-Xymon-Client: Cosmetic changePo-Chuan Hsieh2021-04-181-2/+3 * net-mgmt/p5-Xymon: Cosmetic changePo-Chuan Hsieh2021-04-181-2/+3 * net-mgmt/p5-Net-ACL: Cosmetic changePo-Chuan Hsieh2021-04-181-2/+3 * net-mgmt/p5-MRTG-Parse: Cosmetic changePo-Chuan Hsieh2021-04-181-2/+3 * net-mgmt/p5-Cisco-Reconfig: Cosmetic changePo-Chuan Hsieh2021-04-181-2/+3 * net-mgmt/2ping: Update to 4.5.1Po-Chuan Hsieh2021-04-182-5/+5 * Clean up some thingsTobias Kortkamp2021-04-173-3/+3 * net-mgmt/lldpd: Correct SNMP depsRainer Hurling2021-04-171-4/+2 * net-mgmt/py-prometheus-client: Update to 0.10.0Luca Pizzamiglio2021-04-172-4/+4 * net-mgmt/unifi5: Deprecate and expireMark Felder2021-04-171-0/+3 * net-mgmt/unifi-devel: Deprecate and expireMark Felder2021-04-171-0/+3 * net-mgmt/unifi-lts: Deprecate and expireMark Felder2021-04-171-0/+3 * - Convert VictoriaMetrics ports to master-slave relationship whichAlexey Dokuchaev2021-04-164-57/+17 * Take maintainership, ommitted from previous commit.Dan Langille2021-04-152-2/+2 * Bring back net-mgmt/py-pdagent-integrations & net-mgmt/py-pdagentDan Langille2021-04-1513-0/+286 * net-mgmt/netbox: Update to 2.10.9Kai Knoblich2021-04-153-5/+4 * net-mgmt/telegraf: update to 1.18.1Palle Girgensohn2021-04-152-96/+176 * net-mgmt/nagstamon: add a missing dependencyEmanuel Haupt2021-04-141-2/+4 * net-mgmt/unbound_exporter: Update to v0.3Kevin Bowling2021-04-142-6/+4 * net-mgmt/nagstamon: Fix fetchEmanuel Haupt2021-04-142-5/+4 * net-mgmt/prometheus2: Update to 2.26.0Kevin Bowling2021-04-133-90/+93 * net-mgmt/ocsinventory-agent: Update to 2.8.1Mikael Urankar2021-04-133-30/+9 * net-mgmt/monitoring-plugins: Update to 2.3.1.Mathieu Arnold2021-04-122-4/+4 * net-mgmt/crmsh: fix plist issuesFlorian Smeets2021-04-121-61/+61 * Add net-mgmt/crmsh backFlorian Smeets2021-04-1211-0/+519 * Add a port of ancillary utilities and agent for VictoriaMetrics.Alexey Dokuchaev2021-04-105-0/+139 * Add a port of VictoriaMetrics, fast, cost-effective, and scalableAlexey Dokuchaev2021-04-108-0/+340 * net-mgmt/nagstamon: release was retagged from 3.6 to v3.6.0Emanuel Haupt2021-04-102-4/+6 * Regenerate all distfiles using gitlab as source.Matthias Fechner2021-04-103-7/+6 * zabbix52-server: Fix pkg-plist for zabbix52-javaJuraj Lutter2021-04-091-3/+3 * zabbix5-server: Fix pkg-plist for zabbix5-javaJuraj Lutter2021-04-091-3/+3 * zabbix4-server: Fix pkg-plist for zabbix4-javaJuraj Lutter2021-04-091-3/+3 * net-mgmt/nagstamon: Update to 3.6Emanuel Haupt2021-04-093-22/+8 * net-mgmt/zabbix52-*: Update to 5.2.6Kevin Bowling2021-04-083-4/+7 * net-mgmt/zabbix5-server: Update to 5.0.10Kevin Bowling2021-04-083-4/+7 * net-mgmt/zabbix4-*: Update to 4.0.30Kevin Bowling2021-04-083-4/+7 * net-mgmt/check_ssl_cert: update to 2.0.1Christoph Moench-Tegeder2021-04-072-4/+4 * One more small cleanup, forgotten yesterday.Mathieu Arnold2021-04-07110-110/+0 * all: Remove all other $FreeBSD keywords.Mathieu Arnold2021-04-0695-221/+20 * Remove # $FreeBSD$ from Makefiles.Mathieu Arnold2021-04-06404-406/+0 * update check_ssl_cert to 2.0.0Christoph Moench-Tegeder2021-04-062-4/+4 * Rebuild lang/rust consumers after r569489Tobias Kortkamp2021-03-302-2/+2 * net-mgmt/net-snmp: Fix packaging with Python 3.8 if option PYTHON is setKai Knoblich2021-03-301-1/+1 * Update to 21.3.0Dan Langille2021-03-294-16/+34 * net-mgmt/phpipam: Update to 1.4.2Lewis Cook2021-03-283-12/+14 * Convert to @touchBaptiste Daroussin2021-03-281-2/+2 * net-mgmt/netdata-go: Update to 0.28.1Lewis Cook2021-03-282-6/+6 * update check_ssl_cert to 1.146.0Christoph Moench-Tegeder2021-03-282-4/+4 * net-mgmt/resource-agents: update 4.6.1_1 to 4.8.0Vinícius Zavam2021-03-273-70/+5 * net-mgmt/netbox: Update to 2.10.8Kai Knoblich2021-03-272-6/+6 * net-mgmt/p5-Monitoring-Livestatus: update 0.80_1 to 0.84Vinícius Zavam2021-03-272-5/+4 * net-mgmt/semaphore: update 2.5.2 to 2.6.8Vinícius Zavam2021-03-272-4/+5 * net-mgmt/nagvis: update 1.9.23 to 1.9.25Vinícius Zavam2021-03-272-4/+4 * Remove remnant @stopdaemon it has not been doing anything since 2014Baptiste Daroussin2021-03-27