Skip to content
Snippets Groups Projects
Commit d8eccc29 authored by Alam Ed Arias's avatar Alam Ed Arias
Browse files

Merge remote-tracking branch 'public/strcasestr-swap' into buildbot

parents 1d0cd586 d5816d44
No related branches found
No related tags found
1 merge request!520Fix All the buidlbot issues
...@@ -23,13 +23,6 @@ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT ...@@ -23,13 +23,6 @@ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/ */
#define SWAP( a, b ) \
(\
(a) ^= (b),\
(b) ^= (a),\
(a) ^= (b)\
)
static inline int static inline int
trycmp (char **pp, char *cp, trycmp (char **pp, char *cp,
const char *q, size_t qn) const char *q, size_t qn)
...@@ -45,8 +38,16 @@ trycmp (char **pp, char *cp, ...@@ -45,8 +38,16 @@ trycmp (char **pp, char *cp,
static inline void static inline void
swapp (char ***ppap, char ***ppbp, char **cpap, char **cpbp) swapp (char ***ppap, char ***ppbp, char **cpap, char **cpbp)
{ {
SWAP(*(intptr_t *)ppap, *(intptr_t *)ppbp); char **pp;
SWAP(*(intptr_t *)cpap, *(intptr_t *)cpbp); char *p;
pp = *ppap;
*ppap = *ppbp;
*ppbp = pp;
p = *cpap;
*cpap = *cpbp;
*cpbp = p;
} }
char * char *
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment