2015年11月19日 星期四

[C] Define Error Code


struct errmsg { 
        int     e_code;
        char    *e_msg;
} errmsgs[] = {
        { EUNDEF,       "Undefined error code" },
        { ENOTFOUND,    "File not found" },
        { EACCESS,      "Access violation" },
        { ENOSPACE,     "Disk full or allocation exceeded" },
        { EBADOP,       "Illegal TFTP operation" },
        { EBADID,       "Unknown transfer ID" },
        { EEXISTS,      "File already exists" },
        { ENOUSER,      "No such user" },
        { EOPTNEG,      "Failure to negotiate RFC2347 options" },
        { -1,           0 }
};

Reference:

Related Posts:

0 意見:

張貼留言