libk  Diff

Differences From Artifact [1f7f63c3e2]:

To Artifact [a7232aabca]:


     2      2    * ~ lexi hale <lexi@hale.su>
     3      3    * one of libk's biggest goals is standardization across
     4      4    * software. for this reason, we define here a variety
     5      5    * of "magical numbers" used to signal or describe
     6      6    * various states, messages, and errors. suggestions are
     7      7    * welcome.
     8      8    */
            9  +#ifndef KImagic
           10  +#define KImagic
           11  +
     9     12   #include <k/type.h>
    10     13   
    11     14   typedef enum kbad {
    12     15   	// values to be returned by an entry function
    13     16   	kbad_ok = 0,
    14     17   		/* the requested operation completed
    15     18   		 * successfully */
    16     19   
           20  +	kbad_mem = 1,
           21  +		/* the system does not have enough free
           22  +		 * memory to complete the requested operation */
           23  +
    17     24   	/* these are synchronized with freebsd's existing
    18     25   	 * sysexit.h conventions. */
    19     26   	kbad_usage = 64,
    20     27   		/* # fbsd EX_USAGE
    21     28   		 * a usage screen was displayed to the user
    22     29   		 * on request or due to improperly formed call */
    23     30   	kbad_data = 65,
................................................................................
    61     68   		/* # fbsd EX_NOPERM
    62     69   		 * you or the program do not have permissions
    63     70   		 * to do the thing requested */
    64     71   	kbad_conf = 78,
    65     72   		/* # fbsd EX_CONFIG
    66     73   		 * your configuration is fucked */
    67     74   } kbad;
           75  +
           76  +#endif