"Fossies" - the Fresh Open Source Software Archive

Member "udunits-2.2.28/lib/status.c" (7 Dec 2020, 881 Bytes) of package /linux/privat/udunits-2.2.28.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "status.c" see the Fossies "Dox" file reference documentation and the latest Fossies "Diffs" side-by-side code changes report: 2.2.26_vs_2.2.28.

    1 /*
    2  * Copyright 2020 University Corporation for Atmospheric Research
    3  *
    4  * This file is part of the UDUNITS-2 package.  See the file COPYRIGHT
    5  * in the top-level source-directory of the package for copying and
    6  * redistribution conditions.
    7  */
    8 /*
    9  * Status of the last operation by the UDUNITS2(3) library.
   10  */
   11 
   12 /*LINTLIBRARY*/
   13 
   14 #include "config.h"
   15 
   16 #include "udunits2.h"
   17 
   18 static ut_status        _status = UT_SUCCESS;
   19 
   20 
   21 /*
   22  * Returns the status of the last operation by the units module.  This function
   23  * will not change the status.
   24  */
   25 ut_status
   26 ut_get_status()
   27 {
   28     return _status;
   29 }
   30 
   31 
   32 /*
   33  * Sets the status of the units module.  This function would not normally be
   34  * called by the user unless they were doing their own parsing or formatting.
   35  *
   36  * Arguments:
   37  *  status  The status of the units module.
   38  */
   39 void
   40 ut_set_status(
   41     const ut_status status)
   42 {
   43     _status = status;
   44 }