Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 308813 Details for
Bug 397835
app-arch/rpm2targz: add prefix support
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
add memmem for OS's which mssing it
rpm2targz-9.0.0.4g-memmove.patch (text/plain), 817 bytes, created by
Christoph Junghans (RETIRED)
on 2012-04-13 19:28:52 UTC
(
hide
)
Description:
add memmem for OS's which mssing it
Filename:
MIME Type:
Creator:
Christoph Junghans (RETIRED)
Created:
2012-04-13 19:28:52 UTC
Size:
817 bytes
patch
obsolete
>diff -Naur rpm2targz-9.0.0.4g.orig/rpmoffset.c rpm2targz-9.0.0.4g/rpmoffset.c >--- rpm2targz-9.0.0.4g.orig/rpmoffset.c 2012-04-13 13:09:35.000000000 -0600 >+++ rpm2targz-9.0.0.4g/rpmoffset.c 2012-04-13 13:23:42.000000000 -0600 >@@ -38,6 +38,25 @@ > #define MAGIC_SIZE_MIN 3 > #define MAGIC_SIZE_MAX 6 > >+#if defined(__INTERIX) || (defined (__SVR4) && defined (__sun)) || defined(__MACH__) >+void *memmem(const void *buf, size_t buflen, const void *pattern, size_t len) >+{ >+ char *bf = (char *)buf, *pt = (char *)pattern, *p = bf; >+ >+ while (len <= (buflen - (p - bf))) { >+ if (NULL != (p = memchr(p, (int)(*pt), buflen - (p - bf)))) { >+ if (0 == memcmp(p, pattern, len)) >+ return p; >+ else >+ ++p; >+ } >+ else >+ break; >+ } >+ return NULL; >+} >+#endif >+ > int main(int argc, char *argv[]) > { > int show_magic = 0;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 397835
:
298059
|
298061
| 308813