mirror of
https://github.com/troglobit/libite.git
synced 2026-10-06 23:40:05 +07:00
Fix minor build error in new strndupa() header
Wrong path to local strnlen.h file. Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
+3
-8
@@ -23,9 +23,8 @@
|
||||
* USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
* ==========================================================================
|
||||
*/
|
||||
#ifndef GNU_STRING_STRNDUPA_H
|
||||
#define GNU_STRING_STRNDUPA_H
|
||||
|
||||
#ifndef LITE_STRNDUPA_H_
|
||||
#define LITE_STRNDUPA_H_
|
||||
|
||||
#if !defined(HAVE_STRNDUPA)
|
||||
#if defined(strndupa)
|
||||
@@ -33,14 +32,11 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
#if !HAVE_STRNDUPA
|
||||
#if defined(__GNUC__)
|
||||
#include <stddef.h> /* size_t */
|
||||
|
||||
#include <string.h> /* memcpy(3) */
|
||||
|
||||
#include <gnu/string/strnlen.h>
|
||||
#include "strnlen.h"
|
||||
|
||||
#define strndupa(src, lim) (__extension__ ({ \
|
||||
size_t len_ = strnlen(src, lim); \
|
||||
@@ -54,5 +50,4 @@
|
||||
#endif /* __GNUC__ */
|
||||
#endif /* !HAVE_STRNDUPA */
|
||||
|
||||
|
||||
#endif /* GNU_STRING_STRNDUPA_H */
|
||||
|
||||
@@ -15,8 +15,8 @@
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef LITE_STRNLEN_H
|
||||
#define LITE_STRNLEN_H
|
||||
#ifndef LITE_STRNLEN_H_
|
||||
#define LITE_STRNLEN_H_
|
||||
|
||||
#if !defined(HAVE_STRNLEN)
|
||||
#if defined(strnlen)
|
||||
@@ -24,7 +24,6 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
#if !HAVE_STRNLEN
|
||||
#include <stddef.h> /* size_t */
|
||||
|
||||
@@ -41,4 +40,4 @@ static inline size_t xstrnlen(const char *str, size_t lim)
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* LITE_STRNLEN_H */
|
||||
#endif /* LITE_STRNLEN_H_ */
|
||||
|
||||
Reference in New Issue
Block a user