Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(946)

Unified Diff: c/mmap.c

Issue 2842333002: Updated netty-tcnative to version 2.0.0.Final (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « c/misc.c ('k') | c/multicast.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: c/mmap.c
diff --git a/c/mmap.c b/c/mmap.c
deleted file mode 100644
index b560cbad41a7e209bcd2c87718ddfbba173412b7..0000000000000000000000000000000000000000
--- a/c/mmap.c
+++ /dev/null
@@ -1,102 +0,0 @@
-/* Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*
- *
- * @author Mladen Turk
- * @version $Id: mmap.c 1442587 2013-02-05 13:49:48Z rjung $
- */
-
-#include "tcn.h"
-#include "apr_mmap.h"
-
-TCN_IMPLEMENT_CALL(jlong, Mmap, create)(TCN_STDARGS, jlong file,
- jlong offset, jlong size,
- jint flag, jlong pool)
-{
-#if APR_HAS_MMAP
- apr_pool_t *p = J2P(pool, apr_pool_t *);
- apr_file_t *f = J2P(file, apr_file_t *);
- apr_mmap_t *m = NULL;
-
- UNREFERENCED(o);
- TCN_THROW_IF_ERR(apr_mmap_create(&m, f, (apr_off_t)offset,
- (apr_size_t)size,
- (apr_uint32_t)flag, p), m);
-
-cleanup:
- return P2J(m);
-#else
- UNREFERENCED(o);
- tcn_ThrowAPRException(e, APR_ENOTIMPL);
- return 0;
-#endif
-}
-
-TCN_IMPLEMENT_CALL(jlong, Mmap, dup)(TCN_STDARGS, jlong mmap,
- jlong pool)
-{
-#if APR_HAS_MMAP
- apr_pool_t *p = J2P(pool, apr_pool_t *);
- apr_mmap_t *m = J2P(mmap, apr_mmap_t *);
- apr_mmap_t *newm = NULL;
-
- UNREFERENCED(o);
- TCN_THROW_IF_ERR(apr_mmap_dup(&newm, m, p), newm);
-
-cleanup:
- return P2J(newm);
-#else
- UNREFERENCED(o);
- tcn_ThrowAPRException(e, APR_ENOTIMPL);
- return 0;
-#endif
-}
-
-TCN_IMPLEMENT_CALL(jint, Mmap, delete)(TCN_STDARGS, jlong mmap)
-{
-#if APR_HAS_MMAP
- apr_mmap_t *m = J2P(mmap, apr_mmap_t *);
-
- UNREFERENCED_STDARGS;
- return apr_mmap_delete(m);
-
-#else
- UNREFERENCED_STDARGS;
- UNREFERENCED(mmap);
- return APR_ENOTIMPL;
-#endif
-}
-
-TCN_IMPLEMENT_CALL(jlong, Mmap, offset)(TCN_STDARGS, jlong mmap,
- jlong offset)
-{
-#if APR_HAS_MMAP
- apr_mmap_t *m = J2P(mmap, apr_mmap_t *);
- void *r;
-
- UNREFERENCED(o);
- TCN_THROW_IF_ERR(apr_mmap_offset(&r, m, (apr_off_t)offset), r);
-
-cleanup:
- return P2J(r);
-
-#else
- UNREFERENCED(o);
- tcn_ThrowAPRException(e, APR_ENOTIMPL);
- return 0;
-#endif
-}
« no previous file with comments | « c/misc.c ('k') | c/multicast.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698