mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-17 02:13:35 +02:00
src/nhttpd: clean code
Origin commit data
------------------
Branch: ni/coolstream
Commit: 5e4a541781
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2012-11-28 (Wed, 28 Nov 2012)
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
@@ -8,9 +8,9 @@
|
||||
#include <pthread.h>
|
||||
#include <sys/stat.h>
|
||||
// yhttpd
|
||||
#include "yconfig.h"
|
||||
#include "ytypes_globals.h"
|
||||
#include "helper.h"
|
||||
#include <yconfig.h>
|
||||
#include <ytypes_globals.h>
|
||||
#include <helper.h>
|
||||
#include "mod_cache.h"
|
||||
|
||||
//=============================================================================
|
||||
@@ -128,7 +128,7 @@ void CmodCache::AddToCache(CyhookHandler *, std::string url,
|
||||
CacheList[url].mime_type = mime_type;
|
||||
CacheList[url].category = category;
|
||||
CacheList[url].created = time(NULL);
|
||||
std::string test = CacheList[url].filename;
|
||||
// std::string test = CacheList[url].filename;
|
||||
}
|
||||
fflush(fd); // flush and close file
|
||||
fclose(fd);
|
||||
@@ -154,7 +154,7 @@ void CmodCache::RemoveCategoryFromCache(std::string category) {
|
||||
do {
|
||||
restart = false;
|
||||
TCacheList::iterator i = CacheList.begin();
|
||||
for (; i != CacheList.end(); i++) {
|
||||
for (; i != CacheList.end(); ++i) {
|
||||
TCache *item = &((*i).second);
|
||||
if (item->category == category) {
|
||||
CacheList.erase(((*i).first));
|
||||
@@ -198,7 +198,7 @@ void CmodCache::yshowCacheInfo(CyhookHandler *hh) {
|
||||
"<tr><td>URL</td><td>Mime</td><td>Filename</td><td>Category</td><td>Created</td><td>Remove</td></tr>\n");
|
||||
pthread_mutex_lock(&mutex);
|
||||
TCacheList::iterator i = CacheList.begin();
|
||||
for (; i != CacheList.end(); i++) {
|
||||
for (; i != CacheList.end(); ++i) {
|
||||
TCache *item = &((*i).second);
|
||||
char timeStr[80];
|
||||
strftime(timeStr, sizeof(timeStr), RFC1123FMT, gmtime(&(item->created)));
|
||||
|
Reference in New Issue
Block a user