Permalink
Browse files

Major bug fixes!

  • Loading branch information...
1 parent f1d22a7 commit 4d9c5d7d174e4a19579c42e575401807b22b91d5 @xanmanning xanmanning committed Jun 22, 2010
Showing with 6 additions and 13 deletions.
  1. +0 −8 README.markdown
  2. +1 −1 git.php
  3. +3 −3 security.php
  4. +2 −1 statis.php
View
@@ -27,14 +27,6 @@ Git-PHP is a port of gitweb to PHP. It includes various functionality, such as s
$repo_directory-\
|
- +-.temp\
- |
- +-cache
- |
- +-bundles
- |
- +-secrets
- |
+-project1\.git
|
+-project2\.git
View
@@ -1413,7 +1413,7 @@ function draw_slice($dirname, $commit, $x, $y, $parents, $pin, $vin) {
imagefilledellipse($im, $x * $w + $wo, $ho, $r, $r, $fillcolor);
imageellipse($im, $x * $w + $wo, $ho, $r, $r, $color);
- $filename = $dirname . "/ graph-" . $commit . ".png";
+ $filename = $dirname . "/graph-" . $commit . ".png";
imagepng($im, $filename);
chmod($filename, 0777);
//chgrp($filename, intval(filegroup($CONFIG['repo_directory'])));
View
@@ -139,10 +139,10 @@ function hacker_gaught($mess = "") {
header("Content-Type: text/plain");
echo "please, do not attack.\n";
echo "this site is not your enemy.\n\n";
- echo "the failed argument is $failedarg.\n";
- echo "$mess \n";
+ echo "the failed argument is " . $failedarg . ".\n";
+ echo $mess . " \n";
foreach ($validargs as $va) {
- echo "$va\n";
+ echo $va . "\n";
}
die();
}
View
@@ -41,7 +41,7 @@ function file_stat_get_count($proj, &$today, &$total, $inc, $fbasename) {
$rtoday = 0;
$rtotal = 0;
$now = floor(time()/24/60/60); // number of days since 1970
- $fname = dirname($proj)."/".$CONFIG['cache_name'].$fbasename."-".basename($proj,".git");
+ $fname = $CONFIG['cache_name'] . "/" . basename($proj) . "/" . $fbasename . "-" . basename($proj, ".git");
$fd = 0;
//$fp1 = sem_get(fileinode($fname), 1);
@@ -74,6 +74,7 @@ function file_stat_get_count($proj, &$today, &$total, $inc, $fbasename) {
fseek($file, 0); // rewind the file to beginning
fwrite($file, "$fd $rtoday $rtotal\n");
fclose($file);
+ chmod($fname, 0666);
$today = $rtoday;
$total = $rtotal;
}

0 comments on commit 4d9c5d7

Please sign in to comment.