Map menu key to right amiga to allow clipboard operations on keyboards without right...
[AROS.git] / rom / dos / setcomment.c
blob24ed792a8a0ed4dabe4084ef7a17fd3847afc6f8
1 /*
2 Copyright © 1995-2008, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Set a filecomment.
6 Lang: english
7 */
8 #include <proto/exec.h>
9 #include <dos/dosextens.h>
10 #include <dos/filesystem.h>
11 #include <proto/dos.h>
12 #include "dos_intern.h"
14 /*****************************************************************************
16 NAME */
17 #include <proto/dos.h>
19 AROS_LH2(BOOL, SetComment,
21 /* SYNOPSIS */
22 AROS_LHA(CONST_STRPTR, name, D1),
23 AROS_LHA(CONST_STRPTR, comment, D2),
25 /* LOCATION */
26 struct DosLibrary *, DOSBase, 30, Dos)
28 /* FUNCTION
29 Change the comment on a file or directory. The comment may be any
30 NUL-terminated string. The supported size varies from filesystem
31 to filesystem. In order to clear an existing comment, an empty
32 string should be specified.
34 INPUTS
35 name - name of the file
36 comment - new comment for the file.
38 RESULT
39 Boolean success indicator. IoErr() gives additional information upon
40 failure.
42 NOTES
44 EXAMPLE
46 BUGS
48 SEE ALSO
50 INTERNALS
52 *****************************************************************************/
54 AROS_LIBFUNC_INIT
56 /* Get pointer to I/O request. Use stackspace for now. */
57 struct IOFileSys iofs;
59 /* Prepare I/O request. */
60 InitIOFS(&iofs, FSA_SET_COMMENT, DOSBase);
62 iofs.io_Union.io_SET_COMMENT.io_Comment = comment;
64 return DoIOFS(&iofs, NULL, name, DOSBase) == 0;
66 AROS_LIBFUNC_EXIT
67 } /* SetComment */