#include <atalk/afp.h>
#include <atalk/bstrlib.h>
#include <atalk/bstradd.h>
+#include <atalk/globals.h>
#include "volume.h"
-#include "globals.h"
#include "directory.h"
#include "file.h"
#include "desktop.h"
/* FIXME: pathname too long */
return NULL;
}
- memcpy(p, cfrombstring(dir->d_m_name), blength(dir->d_m_name) + 1);
+ memcpy(p, cfrombstr(dir->d_m_name), blength(dir->d_m_name) + 1);
if ((dir = dirlookup(vol, dir->d_pdid)) == NULL)
return NULL;
}
mpath = obj->newtmp;
mp = makemacpath( vol, mpath, AFPOBJ_TMPSIZ, curdir, path->m_name );
if (!mp) {
+ close(tfd);
return AFPERR_PARAM;
}
mplen = mpath + AFPOBJ_TMPSIZ - mp;
memcpy(p, appltag, sizeof( appltag ));
cc = mpath + AFPOBJ_TMPSIZ - p;
if ( write( tfd, p, cc ) != cc ) {
+ close(tfd);
unlink( tempfile );
return( AFPERR_PARAM );
}
mpath = obj->newtmp;
mp = makemacpath( vol, mpath, AFPOBJ_TMPSIZ, curdir, path->m_name );
if (!mp) {
+ close(tfd);
return AFPERR_PARAM ;
}