X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=etc%2Fafpd%2Fdesktop.c;h=c03f07691d689119001d603adbf40dcf78ab0f1d;hb=df7560dfdb12b06090dc4b2c6e88d0858930b591;hp=a8e71a81dd0e1c228d325a07da9aeb2571792b6c;hpb=30bdec7c3396de87144d5f6d45f11ffa6dad116b;p=netatalk.git diff --git a/etc/afpd/desktop.c b/etc/afpd/desktop.c index a8e71a81..c03f0769 100644 --- a/etc/afpd/desktop.c +++ b/etc/afpd/desktop.c @@ -205,8 +205,8 @@ int afp_addicon(AFPObj *obj, char *ibuf, size_t ibuflen _U_, char *rbuf, size_t addicon_err: if ( cc < 0 ) { if (obj->proto == AFPPROTO_DSI) { - dsi_writeinit(obj->handle, rbuf, buflen); - dsi_writeflush(obj->handle); + dsi_writeinit(obj->dsi, rbuf, buflen); + dsi_writeflush(obj->dsi); } return cc; } @@ -214,7 +214,7 @@ addicon_err: switch (obj->proto) { case AFPPROTO_DSI: { - DSI *dsi = obj->handle; + DSI *dsi = obj->dsi; iovcnt = dsi_writeinit(dsi, rbuf, buflen); @@ -442,7 +442,7 @@ int afp_geticon(AFPObj *obj, char *ibuf, size_t ibuflen _U_, char *rbuf, size_t rc = min( bsize, rsize ); if ((obj->proto == AFPPROTO_DSI) && (buflen < rc)) { - DSI *dsi = obj->handle; + DSI *dsi = obj->dsi; struct stat st; off_t size; @@ -644,7 +644,7 @@ static int ad_addcomment(struct vol *vol, struct path *path, char *ibuf) isadir = path_isadir(path); if (isadir || !(of = of_findname(path))) { - ad_init(&ad, vol->v_adouble, vol->v_ad_options); + ad_init(&ad, vol); adp = &ad; } else adp = of->of_ad; @@ -719,7 +719,7 @@ static int ad_getcomment(struct vol *vol, struct path *path, char *rbuf, size_t upath = path->u_name; isadir = path_isadir(path); if (isadir || !(of = of_findname(path))) { - ad_init(&ad, vol->v_adouble, vol->v_ad_options); + ad_init(&ad, vol); adp = &ad; } else adp = of->of_ad; @@ -796,12 +796,12 @@ static int ad_rmvcomment(struct vol *vol, struct path *path) isadir = path_isadir(path); if (isadir || !(of = of_findname(path))) { - ad_init(&ad, vol->v_adouble, vol->v_ad_options); + ad_init(&ad, vol); adp = &ad; } else adp = of->of_ad; - if ( ad_open(adp, upath, ADFLAGS_HF | ADFLAGS_RDWR | (isadir) ? ADFLAGS_DIR : 0) < 0 ) { + if ( ad_open(adp, upath, ADFLAGS_HF | ADFLAGS_RDWR | ((isadir) ? ADFLAGS_DIR : 0)) < 0 ) { switch ( errno ) { case ENOENT : return( AFPERR_NOITEM );