X-Git-Url: http://git.madism.org/?p=apps%2Fmadtty.git;a=blobdiff_plain;f=madtty%2Fmadtty.c;h=c35959aaee21539f0b3198e0e4b3d76721681a74;hp=1718b8394607459205267dace40c1790fa441319;hb=0b11e26f67ee0114f87c692c0d8f9e66ddf8b9ef;hpb=5e8bd7606f26abce289b94c905db65487926bc9c diff --git a/madtty/madtty.c b/madtty/madtty.c index 1718b83..c35959a 100644 --- a/madtty/madtty.c +++ b/madtty/madtty.c @@ -107,6 +107,7 @@ struct madtty_t { char ebuf[BUFSIZ]; int rlen, elen; madtty_handler_t handler; + void *data; }; typedef struct t_row_t { @@ -1095,3 +1096,13 @@ void madtty_set_handler(madtty_t *t, madtty_handler_t handler) { t->handler = handler; } + +void madtty_set_data(madtty_t *t, void *data) +{ + t->data = data; +} + +void *madtty_get_data(madtty_t *t) +{ + return t->data; +}