apache-modules


Apache module insert text at the head


So upset about this. I am trying to do a very simple thing here.
I try to insert a string at the head of a html file in an Apache module, the code is simple.
apr_bucket* txt_esc(apr_bucket_alloc_t* alloc )
{
return apr_bucket_transient_create("ggggggggggggggg", 15, alloc) ;
}
apr_status_t add_string(ap_filter_t *f, apr_bucket_brigade *pbbIn)
{
APR_BRIGADE_INSERT_HEAD(pbbIn, txt_esc(f->r->connection->bucket_alloc));
return ap_pass_brigade(f->next, pbbIn);
}
The problem is that I can insert the string at the head, but meantime, the content of the same size of the string at the end of the html file will be truncated.
Anybody knows why this happens? This Apache server is running as a proxy.

Related Links

Where can I download apache module binaries from?
Apache module insert text at the head

Categories

HOME
jboss
ionic2
plesk
freeradius
windows-8.1
bokeh
operating-system
stacktrace.js
filesize
adobe
websocket
google-play-services
qooxdoo
gentelella
linker
wagtail
graphql-js
tweepy
kurento
azure-graph-api
lda
fireloop
fbloginview
phpstorm-2017.1
business-intelligence
angular4
jquery-file-upload
stimulsoft
bnf
robolectric
scheduled-tasks
jitsi
activeadmin
workday
qa
chronicle-queue
restier
software-packaging
tracing
prompt
ipa
offline-caching
msdeploy
ninject
nic
vcenter
publishing
quick-nimble
cucumber-junit
cloudera-manager
restful-architecture
dreamfactory
xerces-c
bluemixtools
spinner
xvfb
djcelery
macports
aurelia-http-client
slideshow
klee
fluid-mac-app-engine
zend-form
ipp-protocol
linq-to-excel
rightnow-crm
ssi
icecast
beeline
sigsegv
datediff
android-mediarecorder
dtd
swiperefreshlayout
perl-data-structures
controllers
rational-performance-test
msg
jsf-2.3
mathml
uibinder
exists
sharepoint-apps
textblock
accessibilityservice
gravatar
currency-exchange-rates
management-studio-express
pack
smart-tv
html.actionlink
srv-record
android-studio-import
kefir.js
mojo
category-theory
treeline
android-2.3-gingerbread
commenting
typesafe-stack
lru
html-frames
n-queens
will-paginate
filelock
page-curl
simile
bll
git-log
gaelyk
raw-data
.net-services
browser-based
yahoo-maps

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App