$treeview $search $mathjax $extrastylesheet
librsync
2.0.2
$projectbrief
|
$projectbrief
|
$searchbox |
00001 /*= -*- c-basic-offset: 4; indent-tabs-mode: nil; -*- 00002 * 00003 * librsync -- the library for network deltas 00004 * 00005 * Copyright (C) 2000, 2001 by Martin Pool <mbp@sourcefrog.net> 00006 * 00007 * This program is free software; you can redistribute it and/or 00008 * modify it under the terms of the GNU Lesser General Public License 00009 * as published by the Free Software Foundation; either version 2.1 of 00010 * the License, or (at your option) any later version. 00011 * 00012 * This program is distributed in the hope that it will be useful, but 00013 * WITHOUT ANY WARRANTY; without even the implied warranty of 00014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00015 * Lesser General Public License for more details. 00016 * 00017 * You should have received a copy of the GNU Lesser General Public 00018 * License along with this program; if not, write to the Free Software 00019 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00020 */ 00021 00022 /*= 00023 | Welcome to Arco AM/PM Mini-Market. We 00024 | would like to advise our customers 00025 | that any individual who offers to 00026 | pump gas, wash windows or solicit 00027 | products is not employed by or 00028 | associated with this facility. We 00029 | discourage any contact with these 00030 | individuals and ask that you report 00031 | any problems to uniformed personal 00032 | inside. Thankyou for shopping at 00033 | Arco, and have a nice day. 00034 */ 00035 00036 /** \file msg.c error messages for re_result values. 00037 * 00038 * \todo (Suggestion by tridge) Add a function which outputs a complete text 00039 * description of a job, including only the fields relevant to the current 00040 * encoding function. */ 00041 00042 #include "config.h" 00043 00044 #include <stdlib.h> 00045 #include <stdio.h> 00046 00047 #include "librsync.h" 00048 00049 char const *rs_strerror(rs_result r) 00050 { 00051 switch (r) { 00052 case RS_DONE: 00053 return "OK"; 00054 case RS_RUNNING: 00055 return "still running"; 00056 case RS_BLOCKED: 00057 return "blocked waiting for input or output buffers"; 00058 case RS_BAD_MAGIC: 00059 return "bad magic number at start of stream"; 00060 case RS_INPUT_ENDED: 00061 return "unexpected end of input"; 00062 case RS_CORRUPT: 00063 return "stream corrupt"; 00064 case RS_UNIMPLEMENTED: 00065 return "unimplemented case"; 00066 case RS_MEM_ERROR: 00067 return "out of memory"; 00068 case RS_IO_ERROR: 00069 return "IO error"; 00070 case RS_SYNTAX_ERROR: 00071 return "bad command line syntax"; 00072 case RS_INTERNAL_ERROR: 00073 return "library internal error"; 00074 00075 default: 00076 return "unexplained problem"; 00077 } 00078 }