]> mj.ucw.cz Git - libucw.git/commitdiff
Signals: Documentation
authorMartin Mares <mj@ucw.cz>
Wed, 18 Jul 2012 09:32:44 +0000 (11:32 +0200)
committerMartin Mares <mj@ucw.cz>
Wed, 18 Jul 2012 09:32:44 +0000 (11:32 +0200)
ucw/doc/Makefile
ucw/doc/index.txt
ucw/doc/signal.txt [new file with mode: 0644]
ucw/signames.h

index 92561d5088e5bf268ceb58ac3b9fcb59be83bb2e..4da7cf8c49068e63ca542068db2b14aef6edaf59 100644 (file)
@@ -2,7 +2,7 @@
 
 DIRS+=ucw/doc
 
-UCW_DOCS=basics log fastbuf index config configure install basecode hash docsys conf mempool eltpool mainloop generic growbuf unaligned lists chartype unicode prime binsearch heap binheap compress sort hashtable relnotes trans string time daemon
+UCW_DOCS=basics log fastbuf index config configure install basecode hash docsys conf mempool eltpool mainloop generic growbuf unaligned lists chartype unicode prime binsearch heap binheap compress sort hashtable relnotes trans string time daemon signal
 UCW_INDEX=$(o)/ucw/doc/def_index.html
 UCW_DOCS_HTML=$(addprefix $(o)/ucw/doc/,$(addsuffix .html,$(UCW_DOCS)))
 
index 8ac58c9272d767fb443539b822e5023b312f53cd..e449c755064ed77628f893a27488887217ca5e24 100644 (file)
@@ -41,6 +41,7 @@ Modules
 - <<string:,String operations>>
 - <<time:,Time and timers>>
 - <<daemon:,Daemon helpers>>
+- <<signal:,Signal helpers>>
 
 Other features
 --------------
diff --git a/ucw/doc/signal.txt b/ucw/doc/signal.txt
new file mode 100644 (file)
index 0000000..b78f065
--- /dev/null
@@ -0,0 +1,7 @@
+Signal helpers
+==============
+
+ucw/signames.h
+--------------
+
+!!ucw/signames.h
index d7b9cac7bc9ac4e1c336aabd543ef775dce98e48..0876bab54946419246f1824ad377116189436cad 100644 (file)
@@ -7,8 +7,25 @@
 #ifndef _UCW_SIGNAMES_H
 #define _UCW_SIGNAMES_H
 
+/***
+ * POSIX lacks facilities for conversion between signal names
+ * and signal numbers. They are available in LibUCW, but please
+ * be aware that some signals might be missing on your system.
+ * If they do, please notify LibUCW maintainers.
+ ***/
+
+/**
+ * Converts signal name to the corresponding number.
+ * Returns -1 if not found.
+ **/
 int sig_name_to_number(const char *name);
 
+/**
+ * Converts signal number to the corresponding name.
+ * If more names are known for the given signal, one of them
+ * is considered canonical and preferred.
+ * Returns NULL if not found.
+ **/
 const char *sig_number_to_name(int number);
 
 #endif