Mercurial > ~mikael > mcabber > hg
annotate mcabber/src/utils.h @ 589:9942746e8d58
Improve fix from changeset 1b773c760a99
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Sat, 10 Dec 2005 20:17:49 +0100 |
parents | fed6d1e4d7a9 |
children | 67a332121aea |
rev | line source |
---|---|
24 | 1 #ifndef __UTILS_H__ |
2 #define __UTILS_H__ 1 | |
3 | |
469
a926523d2392
Use UTF8 to handle resources and room nicknames
Mikael Berthe <mikael@lilotux.net>
parents:
452
diff
changeset
|
4 #define to_utf8(s) ((s) ? g_locale_to_utf8((s), -1, NULL,NULL,NULL) : NULL) |
a926523d2392
Use UTF8 to handle resources and room nicknames
Mikael Berthe <mikael@lilotux.net>
parents:
452
diff
changeset
|
5 #define from_utf8(s) ((s) ? g_locale_from_utf8((s), -1, NULL,NULL,NULL) : NULL) |
a926523d2392
Use UTF8 to handle resources and room nicknames
Mikael Berthe <mikael@lilotux.net>
parents:
452
diff
changeset
|
6 |
281
f562b9af2de7
Add "const" specifier in prototypes
Mikael Berthe <mikael@lilotux.net>
parents:
241
diff
changeset
|
7 void ut_InitDebug(unsigned int level, const char *file); |
374
bd5638c21834
Improve logging system (traces)
Mikael Berthe <mikael@lilotux.net>
parents:
364
diff
changeset
|
8 void ut_WriteLog(unsigned int flag, const char *data); |
24 | 9 |
362
d8f147d6e872
Check directory and config file permissions
Mikael Berthe <mikael@lilotux.net>
parents:
281
diff
changeset
|
10 int checkset_perm(const char *name, unsigned int setmode); |
d8f147d6e872
Check directory and config file permissions
Mikael Berthe <mikael@lilotux.net>
parents:
281
diff
changeset
|
11 |
524
05c0e55c4bb1
Pass message body to external command
Mikael Berthe <mikael@lilotux.net>
parents:
469
diff
changeset
|
12 const char *ut_get_tmpdir(void); |
05c0e55c4bb1
Pass message body to external command
Mikael Berthe <mikael@lilotux.net>
parents:
469
diff
changeset
|
13 |
241 | 14 int to_iso8601(char *dststr, time_t timestamp); |
15 time_t from_iso8601(const char *timestamp, int utc); | |
16 | |
419 | 17 inline void safe_usleep(unsigned int usec); /* Only for delays < 1s */ |
18 | |
452 | 19 int check_jid_syntax(char *jid); |
20 | |
21 void mc_strtolower(char *str); | |
22 | |
554
2424bbf0a6db
Some more work on do_room()
Mikael Berthe <mikael@lilotux.net>
parents:
551
diff
changeset
|
23 void strip_arg_special_chars(char *s); |
2424bbf0a6db
Some more work on do_room()
Mikael Berthe <mikael@lilotux.net>
parents:
551
diff
changeset
|
24 char **split_arg(const char *arg, unsigned int n, int dontstriplast); |
551
c71699efa5cc
Add split_arg() / free_arg_lst()
Mikael Berthe <mikael@lilotux.net>
parents:
524
diff
changeset
|
25 void free_arg_lst(char **arglst); |
c71699efa5cc
Add split_arg() / free_arg_lst()
Mikael Berthe <mikael@lilotux.net>
parents:
524
diff
changeset
|
26 |
24 | 27 #endif |
576 | 28 |
580 | 29 /* vim: set expandtab cindent cinoptions=>2\:2(0: For Vim users... */ |