repo
stringlengths
1
152
file
stringlengths
14
221
code
stringlengths
501
25k
file_length
int64
501
25k
avg_line_length
float64
20
99.5
max_line_length
int64
21
134
extension_type
stringclasses
2 values
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/linux_priv.c
#include "config.h" #include <seccomp.h> #include <errno.h> #include <stdlib.h> #include "memcached.h" // In the future when the system is more tested this could be switched // to SCMP_ACT_KILL instead. #define DENY_ACTION SCMP_ACT_ERRNO(EACCES) void drop_privileges(void) { scmp_filter_ctx ctx = seccomp_init(DENY...
4,495
38.438596
97
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/itoa_ljust.h
#ifndef ITOA_LJUST_H #define ITOA_LJUST_H //=== itoa_ljust.h - Fast integer to ascii conversion // // Fast and simple integer to ASCII conversion: // // - 32 and 64-bit integers // - signed and unsigned // - user supplied buffer must be large enough for all decimal digits // in value plus minus sign if negat...
822
27.37931
80
h
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/murmur3_hash.h
//----------------------------------------------------------------------------- // MurmurHash3 was written by Austin Appleby, and is placed in the public // domain. The author hereby disclaims copyright to this source code. #ifndef MURMURHASH3_H #define MURMURHASH3_H //------------------------------------------------...
681
33.1
79
h
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/itoa_ljust.c
//=== itoa_ljust.cpp - Fast integer to ascii conversion --*- C++ -*-// // // Substantially simplified (and slightly faster) version // based on the following functions in Google's protocol buffers: // // FastInt32ToBufferLeft() // FastUInt32ToBufferLeft() // FastInt64ToBufferLeft() // FastUInt64To...
5,242
33.953333
80
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/util.h
/* fast-enough functions for uriencoding strings. */ void uriencode_init(void); bool uriencode(const char *src, char *dst, const size_t srclen, const size_t dstlen); /* * Wrappers around strtoull/strtoll that are safer and easier to * use. For tests and assumptions, see internal_tests.c. * * str a NULL-terminat...
1,127
27.923077
85
h
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/protocol_binary.h
/* * Copyright (c) <2008>, Sun Microsystems, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * Redistributions of source code must retain the above copyright * notice, this...
16,525
34.087049
80
h
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/timedrun.c
#include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <signal.h> #include <sys/wait.h> #include <sysexits.h> #include <assert.h> static int caught = 0; static void caught_signal(int which) { caught = which; } static int wait_for_process(pid_t pid) { int rv = EX_SOFTWARE; int stats = 0; ...
2,416
22.466019
70
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/hash.c
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */ #include "memcached.h" #include "jenkins_hash.h" #include "murmur3_hash.h" int hash_init(enum hashfunc_type type) { switch(type) { case JENKINS_HASH: hash = jenkins_hash; settings.hash_algorithm = "jenkin...
539
23.545455
77
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/items.h
/* * Copyright 2018 Lenovo * * Licensed under the BSD-3 license. see LICENSE.Lenovo.txt for full text */ /* * Note: * Codes enclosed in `#ifdef PSLAB' and `#endif' are added by Lenovo for * persistent memory support */ #define HOT_LRU 0 #define WARM_LRU 64 #define COLD_LRU 128 #define TEMP_LRU 192 #define ...
3,550
31.577982
120
h
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/trace.h
#ifndef TRACE_H #define TRACE_H #ifdef ENABLE_DTRACE #include "memcached_dtrace.h" #else #define MEMCACHED_ASSOC_DELETE(arg0, arg1, arg2) #define MEMCACHED_ASSOC_DELETE_ENABLED() (0) #define MEMCACHED_ASSOC_FIND(arg0, arg1, arg2) #define MEMCACHED_ASSOC_FIND_ENABLED() (0) #define MEMCACHED_ASSOC_INSERT(arg0, arg1, arg...
3,179
43.166667
66
h
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/cache.h
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */ #ifndef CACHE_H #define CACHE_H #include <pthread.h> #ifdef HAVE_UMEM_H #include <umem.h> #define cache_t umem_cache_t #define cache_alloc(a) umem_cache_alloc(a, UMEM_DEFAULT) #define do_cache_alloc(a) umem_cache_alloc(a, UMEM_DEFAULT) #defi...
4,498
36.181818
92
h
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/sasl_defs.c
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */ #include "memcached.h" #include <stdio.h> #include <stdlib.h> #include <string.h> #include <sasl/saslplug.h> char my_sasl_hostname[1025]; #ifdef HAVE_SASL_CB_GETCONF /* The locations we may search for a SASL config file if the user didn't ...
5,091
25.659686
93
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/bipbuffer.h
#ifndef BIPBUFFER_H #define BIPBUFFER_H typedef struct { unsigned long int size; /* region A */ unsigned int a_start, a_end; /* region B */ unsigned int b_end; /* is B inuse? */ int b_inuse; unsigned char data[]; } bipbuf_t; /** * Create a new bip buffer. * * malloc()s space * ...
2,118
23.079545
74
h
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/solaris_priv.c
#include <stdlib.h> #include <priv.h> #include <stdio.h> #include "memcached.h" /* * this section of code will drop all (Solaris) privileges including * those normally granted to all userland process (basic privileges). The * effect of this is that after running this code, the process will not able * to fork(), ex...
1,259
27
76
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/jenkins_hash.c
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */ /* * Hash table * * The hash function used here is by Bob Jenkins, 1996: * <http://burtleburtle.net/bob/hash/doobs.html> * "By Bob Jenkins, 1996. bob_jenkins@burtleburtle.net. * You may use this code any way you wish, pr...
14,709
33.050926
79
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/pslab.c
/* * Copyright 2018 Lenovo * * Licensed under the BSD-3 license. see LICENSE.Lenovo.txt for full text */ #include "memcached.h" #include <stddef.h> #include <string.h> #define PSLAB_POOL_SIG "PMCH" #define PSLAB_POOL_SIG_SIZE 4 #define PSLAB_POOL_VER_SIZE 12 #define PSLAB_ALIGN_MASK 0xfffffff8 #pragma pack(1) /*...
11,972
29.7
88
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/murmur3_hash.c
//----------------------------------------------------------------------------- // MurmurHash3 was written by Austin Appleby, and is placed in the public // domain. The author hereby disclaims copyright to this source code. // Note - The x86 and x64 versions do _not_ produce the same results, as the // algorithms are ...
2,826
21.616
79
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/daemon.c
/* $Header: /cvsroot/wikipedia/willow/src/bin/willow/daemon.c,v 1.1 2005/05/02 19:15:21 kateturner Exp $ */ /* $NetBSD: daemon.c,v 1.9 2003/08/07 16:42:46 agc Exp $ */ /*- * Copyright (c) 1990, 1993 * The Regents of the University of California. All rights reserved. * * Redistribution and use in sou...
3,082
33.255556
122
c
null
NearPMSW-main/nearpm/logging/memcached-pmem-NDP/crc32c.c
/* crc32c.c -- compute CRC-32C using the Intel crc32 instruction * Copyright (C) 2013 Mark Adler * Version 1.1 1 Aug 2013 Mark Adler */ /* This software is provided 'as-is', without any express or implied warranty. In no event will the author be held liable for any damages arising from the use of this soft...
11,318
31.90407
79
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/anet.c
/* anet.c -- Basic TCP socket stuff made a bit less boring * * Copyright (c) 2006-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * ...
20,633
30.454268
90
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/blocked.c
/* blocked.c - generic support for blocking operations like BLPOP & WAIT. * * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions ...
7,966
40.712042
87
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/help.h
/* Automatically generated by utils/generate-command-help.rb, do not edit. */ #ifndef __REDIS_HELP_H #define __REDIS_HELP_H static char *commandGroups[] = { "generic", "string", "list", "set", "sorted_set", "hash", "pubsub", "transactions", "connection", "server", "scriptin...
24,462
23.030452
134
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/sha1.h
#ifndef SHA1_H #define SHA1_H /* ================ sha1.h ================ */ /* SHA-1 in C By Steve Reid <steve@edmweb.com> 100% Public Domain */ typedef struct { uint32_t state[5]; uint32_t count[2]; unsigned char buffer[64]; } SHA1_CTX; void SHA1Transform(uint32_t state[5], const unsigned char buffer[64...
566
21.68
76
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/config.h
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
6,550
30.195238
130
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/ae_epoll.c
/* Linux epoll(2) based ae.c module * * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of ...
4,846
34.639706
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/ae_select.c
/* Select()-based ae.c module. * * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of sourc...
3,828
34.785047
78
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/intset.c
/* * Copyright (c) 2009-2012, Pieter Noordhuis <pcnoordhuis at gmail dot com> * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following condition...
16,271
32.006085
79
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/bio.h
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
2,073
48.380952
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/setproctitle.c
/* ========================================================================== * setproctitle.c - Linux/Darwin setproctitle. * -------------------------------------------------------------------------- * Copyright (C) 2010 William Ahern * Copyright (C) 2013 Salvatore Sanfilippo * Copyright (C) 2013 Stam He * *...
5,656
20.591603
92
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/util.c
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
22,734
29.394385
102
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/ae.h
/* A simple event-driven programming library. Originally I wrote this code * for the Jim's event-loop (Jim is a Tcl interpreter) but later translated * it in form of a library for easy reuse. * * Copyright (c) 2006-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution an...
4,681
36.758065
91
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/multi.c
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
11,229
33.660494
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/lzf_d.c
/* * Copyright (c) 2000-2010 Marc Alexander Lehmann <schmorp@schmorp.de> * * Redistribution and use in source and binary forms, with or without modifica- * tion, are permitted provided that the following conditions are met: * * 1. Redistributions of source code must retain the above copyright notice, * ...
6,088
31.736559
109
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/sha1.c
/* from valgrind tests */ /* ================ sha1.c ================ */ /* SHA-1 in C By Steve Reid <steve@edmweb.com> 100% Public Domain Test Vectors (from FIPS PUB 180-1) "abc" A9993E36 4706816A BA3E2571 7850C26C 9CD0D89D "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq" 84983E44 1C3BD26E BAAE4AA1 F9...
7,252
30.811404
84
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/bio.c
/* Background I/O service for Redis. * * This file implements operations that we need to perform in the background. * Currently there is only a single operation, that is a background close(2) * system call. This is needed as when the process is the last owner of a * reference to a file closing it means unlinking i...
9,103
38.929825
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/notify.c
/* * Copyright (c) 2013, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyrig...
5,418
40.366412
78
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/debugmacro.h
/* This file contains debugging macros to be used when investigating issues. * * ----------------------------------------------------------------------------- * * Copyright (c) 2016, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with...
2,356
55.119048
80
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/intset.h
/* * Copyright (c) 2009-2012, Pieter Noordhuis <pcnoordhuis at gmail dot com> * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following condition...
2,296
40.763636
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/rio.c
/* rio.c is a simple stream-oriented I/O abstraction that provides an interface * to write code that can consume/produce data using different concrete input * and output devices. For instance the same rdb.c code using the rio * abstraction can be used to read and write the RDB format using in-memory * buffers or fi...
12,104
33.389205
81
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/ae_evport.c
/* ae.c module for illumos event ports. * * Copyright (c) 2012, Joyent, Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyr...
10,939
33.080997
81
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/sds.h
/* SDSLib 2.0 -- A C dynamic strings library * * Copyright (c) 2006-2015, Salvatore Sanfilippo <antirez at gmail dot com> * Copyright (c) 2015, Oran Agra * Copyright (c) 2015, Redis Labs, Inc * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permit...
9,170
31.178947
88
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/redisassert.h
/* redisassert.h -- Drop in replacemnet assert.h that prints the stack trace * in the Redis logs. * * This file should be included instead of "assert.h" inside libraries used by * Redis that are using assertions, so instead of Redis disappearing with * SIGABORT, we get the details and stack trace ...
2,276
46.4375
83
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/anet.h
/* anet.c -- Basic TCP socket stuff made a bit less boring * * Copyright (c) 2006-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * ...
3,562
42.987654
93
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/lzfP.h
/* * Copyright (c) 2000-2007 Marc Alexander Lehmann <schmorp@schmorp.de> * * Redistribution and use in source and binary forms, with or without modifica- * tion, are permitted provided that the following conditions are met: * * 1. Redistributions of source code must retain the above copyright notice, * ...
5,826
30.327957
79
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/sdsalloc.h
/* SDSLib 2.0 -- A C dynamic strings library * * Copyright (c) 2006-2015, Salvatore Sanfilippo <antirez at gmail dot com> * Copyright (c) 2015, Redis Labs, Inc * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following c...
2,083
47.465116
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/ae.c
/* A simple event-driven programming library. Originally I wrote this code * for the Jim's event-loop (Jim is a Tcl interpreter) but later translated * it in form of a library for easy reuse. * * Copyright (c) 2006-2010, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution an...
15,529
32.32618
83
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/testhelp.h
/* This is a really minimal testing framework for C. * * Example: * * test_cond("Check if 1 == 1", 1==1) * test_cond("Check if 5 > 10", 5 > 10) * test_report() * * ---------------------------------------------------------------------------- * * Copyright (c) 2010-2012, Salvatore Sanfilippo <antirez at gmail d...
2,431
40.931034
79
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/ziplist.h
/* * Copyright (c) 2009-2012, Pieter Noordhuis <pcnoordhuis at gmail dot com> * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following condition...
2,890
49.719298
104
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/fmacros.h
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
2,147
33.645161
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/pqsort.h
/* The following is the NetBSD libc qsort implementation modified in order to * support partial sorting of ranges for Redis. * * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, a...
1,964
46.926829
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/slowlog.h
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
2,197
44.791667
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/util.h
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
2,303
42.471698
81
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/t_hash.c
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
24,913
30.026152
85
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/sparkline.c
/* sparkline.c -- ASCII Sparklines * This code is modified from http://github.com/antirez/aspark and adapted * in order to return SDS strings instead of outputting directly to * the terminal. * * --------------------------------------------------------------------------- * * Copyright(C) 2011-2014 Salvatore Sanf...
6,588
36.225989
102
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/ae_kqueue.c
/* Kqueue(2)-based ae.c module * * Copyright (C) 2009 Harish Mallipeddi - harish.mallipeddi@gmail.com * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code...
4,567
31.863309
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/rdb.h
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
5,003
40.7
93
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/latency.h
/* latency.h -- latency monitor API header file * See latency.c for more information. * * ---------------------------------------------------------------------------- * * Copyright (c) 2014, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary fo...
3,914
40.648936
80
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/slowlog.c
/* Slowlog implements a system that is able to remember the latest N * queries that took more than M microseconds to execute. * * The execution time to reach to be logged in the slow log is set * using the 'slowlog-log-slower-than' config directive, that is also * readable and writable using the CONFIG SET/GET com...
6,716
38.511765
83
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/lzf.h
/* * Copyright (c) 2000-2008 Marc Alexander Lehmann <schmorp@schmorp.de> * * Redistribution and use in source and binary forms, with or without modifica- * tion, are permitted provided that the following conditions are met: * * 1. Redistributions of source code must retain the above copyright notice, * ...
4,407
42.643564
79
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/rand.c
/* Pseudo random number generation functions derived from the drand48() * function obtained from pysam source code. * * This functions are used in order to replace the default math.random() * Lua implementation with something having exactly the same behavior * across different systems (by default Lua uses libc's r...
3,848
39.946809
79
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/rand.h
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
1,763
44.230769
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/pqsort.c
/* The following is the NetBSD libc qsort implementation modified in order to * support partial sorting of ranges for Redis. * * Copyright(C) 2009-2012 Salvatore Sanfilippo. All rights reserved. * * The original copyright notice follows. */ /* $NetBSD: qsort.c,v 1.19 2009/01/30 23:38:44 lukem Exp $ */ /*- * Co...
5,528
28.725806
79
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/memtest.c
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
13,441
36.235457
93
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/pmem.c
/* * Copyright (c) 2017, Andreas Bluemle <andreas dot bluemle at itxperts dot de> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the abov...
6,248
32.596774
118
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/solarisfixes.h
/* Solaris specific fixes. * * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source co...
2,201
39.036364
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/quicklist.h
/* quicklist.h - A generic doubly linked quicklist implementation * * Copyright (c) 2014, Matt Stancliff <matt@genges.com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistrib...
7,808
44.935294
80
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/redis-check-rdb.c
/* * Copyright (c) 2016, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyrig...
12,789
35.965318
91
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/asciilogo.h
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
2,833
58.041667
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/syncio.c
/* Synchronous socket and file I/O operations useful across the core. * * Copyright (c) 2009-2010, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are ...
5,580
37.226027
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/lzf_c.c
/* * Copyright (c) 2000-2010 Marc Alexander Lehmann <schmorp@schmorp.de> * * Redistribution and use in source and binary forms, with or without modifica- * tion, are permitted provided that the following conditions are met: * * 1. Redistributions of source code must retain the above copyright notice, * ...
9,012
29.866438
93
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/endianconv.c
/* endinconv.c -- Endian conversions utilities. * * This functions are never called directly, but always using the macros * defined into endianconv.h, this way we define everything is a non-operation * if the arch is already little endian. * * Redis tries to encode everything as little endian (but a few things th...
3,777
28.286822
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/crc16.c
#include "server.h" /* * Copyright 2001-2010 Georges Menie (www.menie.org) * Copyright 2010-2012 Salvatore Sanfilippo (adapted to Redis coding style) * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions ...
4,477
49.314607
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/adlist.h
/* adlist.h - A generic doubly linked list implementation * * Copyright (c) 2006-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * ...
3,451
35.723404
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/sparkline.h
/* sparkline.h -- ASCII Sparklines header file * * --------------------------------------------------------------------------- * * Copyright(C) 2011-2014 Salvatore Sanfilippo <antirez@gmail.com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are per...
2,345
40.157895
101
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/pmem.h
/* * Copyright (c) 2017, Andreas Bluemle <andreas dot bluemle at itxperts dot de> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the abov...
2,040
41.520833
79
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/t_string.c
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
15,972
30.946
127
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/dict.h
/* Hash Tables Implementation. * * This file implements in-memory hash tables with insert/del/replace/find/ * get-random-element operations. Hash tables will auto-resize if needed * tables of power of two in size are used, collisions are handled by * chaining. See the source code for more information... :) * * C...
7,201
36.123711
87
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/zmalloc.c
/* zmalloc - total amount of allocated memory aware version of malloc() * * Copyright (c) 2009-2010, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions ar...
12,846
29.299528
94
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/sort.c
/* SORT command and helper functions. * * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions o...
22,327
36.780034
84
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/release.c
/* * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above co...
2,163
39.830189
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/crc64.c
/* Redis uses the CRC64 variant with "Jones" coefficients and init value of 0. * * Specification of this CRC64 variant follows: * Name: crc-64-jones * Width: 64 bites * Poly: 0xad93d23594c935a9 * Reflected In: True * Xor_In: 0xffffffffffffffff * Reflected_Out: True * Xor_Out: 0x0 * Check("123456789"): 0xe9c6d...
10,717
53.683673
78
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/adlist.c
/* adlist.c - A generic doubly linked list implementation * * Copyright (c) 2006-2010, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * ...
9,657
27.744048
78
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/rio.h
/* * Copyright (c) 2009-2012, Pieter Noordhuis <pcnoordhuis at gmail dot com> * Copyright (c) 2009-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following condition...
5,290
36.260563
123
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/src/endianconv.h
/* See endianconv.c top comments for more information * * ---------------------------------------------------------------------------- * * Copyright (c) 2011-2012, Salvatore Sanfilippo <antirez at gmail dot com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modi...
2,901
35.734177
79
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/linenoise/linenoise.h
/* linenoise.h -- VERSION 1.0 * * Guerrilla line editing library against the idea that a line editing lib * needs to be 20,000 lines of C code. * * See linenoise.c for more information. * * ------------------------------------------------------------------------ * * Copyright (c) 2010-2014, Salvatore Sanfilipp...
2,825
37.189189
80
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/linenoise/example.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include "linenoise.h" void completion(const char *buf, linenoiseCompletions *lc) { if (buf[0] == 'h') { linenoiseAddCompletion(lc,"hello"); linenoiseAddCompletion(lc,"hello there"); } } char *hints(const char *buf, int *color, int *b...
2,425
31.346667
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/dict.c
/* Hash table implementation. * * This file implements in memory hash tables with insert/del/replace/find/ * get-random-element operations. Hash tables will auto resize if needed * tables of power of two in size are used, collisions are handled by * chaining. See the source code for more information... :) * * Co...
10,549
30.120944
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/net.c
/* Extracted from anet.c to work properly with Hiredis error reporting. * * Copyright (c) 2006-2011, Salvatore Sanfilippo <antirez at gmail dot com> * Copyright (c) 2010-2011, Pieter Noordhuis <pcnoordhuis at gmail dot com> * * All rights reserved. * * Redistribution and use in source and binary forms, with or w...
12,238
30.955614
95
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/net.h
/* Extracted from anet.c to work properly with Hiredis error reporting. * * Copyright (c) 2006-2011, Salvatore Sanfilippo <antirez at gmail dot com> * Copyright (c) 2010-2011, Pieter Noordhuis <pcnoordhuis at gmail dot com> * * All rights reserved. * * Redistribution and use in source and binary forms, with or w...
2,453
46.192308
103
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/sds.h
/* SDSLib 2.0 -- A C dynamic strings library * * Copyright (c) 2006-2015, Salvatore Sanfilippo <antirez at gmail dot com> * Copyright (c) 2015, Oran Agra * Copyright (c) 2015, Redis Labs, Inc * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permit...
8,934
31.609489
88
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/hiredis.h
/* * Copyright (c) 2009-2011, Salvatore Sanfilippo <antirez at gmail dot com> * Copyright (c) 2010-2011, Pieter Noordhuis <pcnoordhuis at gmail dot com> * * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following condit...
9,403
41.552036
96
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/sdsalloc.h
/* SDSLib 2.0 -- A C dynamic strings library * * Copyright (c) 2006-2015, Salvatore Sanfilippo <antirez at gmail dot com> * Copyright (c) 2015, Redis Labs, Inc * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following c...
2,083
47.465116
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/dict.h
/* Hash table implementation. * * This file implements in memory hash tables with insert/del/replace/find/ * get-random-element operations. Hash tables will auto resize if needed * tables of power of two in size are used, collisions are handled by * chaining. See the source code for more information... :) * * Co...
4,691
35.944882
80
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/adapters/ae.h
/* * Copyright (c) 2010-2011, Pieter Noordhuis <pcnoordhuis at gmail dot com> * * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above...
4,219
31.96875
82
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/adapters/libevent.h
/* * Copyright (c) 2010-2011, Pieter Noordhuis <pcnoordhuis at gmail dot com> * * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above...
3,980
35.522936
80
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/adapters/libev.h
/* * Copyright (c) 2010-2011, Pieter Noordhuis <pcnoordhuis at gmail dot com> * * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above...
4,587
30
78
h
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/examples/example-libev.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <signal.h> #include <hiredis.h> #include <async.h> #include <adapters/libev.h> void getCallback(redisAsyncContext *c, void *r, void *privdata) { redisReply *reply = r; if (reply == NULL) return; printf("argv[%s]: %s\n", (char*)privdata, r...
1,405
25.528302
87
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/examples/example.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <hiredis.h> int main(int argc, char **argv) { unsigned int j; redisContext *c; redisReply *reply; const char *hostname = (argc > 1) ? argv[1] : "127.0.0.1"; int port = (argc > 2) ? atoi(argv[2]) : 6379; struct timeval timeout...
2,236
27.316456
80
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/examples/example-libuv.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <signal.h> #include <hiredis.h> #include <async.h> #include <adapters/libuv.h> void getCallback(redisAsyncContext *c, void *r, void *privdata) { redisReply *reply = r; if (reply == NULL) return; printf("argv[%s]: %s\n", (char*)privdata, r...
1,445
25.777778
87
c
null
NearPMSW-main/nearpm/logging/redis/redis-NDP/deps/hiredis/examples/example-ae.c
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <signal.h> #include <hiredis.h> #include <async.h> #include <adapters/ae.h> /* Put event loop in the global scope, so it can be explicitly stopped */ static aeEventLoop *loop; void getCallback(redisAsyncContext *c, void *r, void *privdata) { red...
1,583
24.142857
87
c