• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#objective-cqtwindows誰得cocoapythonphprubygameguibathyscaphec翻訳omegat計画中(planning stage)frameworktwittertestdomvb.netdirectxbtronarduinopreviewerゲームエンジン

ギコナビ


Commit MetaInfo

修订版c6aeec9e6c2a0b0e6351a02565b731aaadc35d3b (tree)
时间2008-09-21 10:26:52
作者cvs2git <cvs2git>
Commitercvs2git

Log Message

This commit was manufactured by cvs2svn to create tag 'v1_59_0_767'.

更改概述

差异

--- a/Editor.pas
+++ b/Editor.pas
@@ -249,6 +249,8 @@ type
249249 function LFusianaGet(const s: String): Boolean;
250250 // Cookie‚̎擾
251251 procedure GetCookie(Rawtext: String; ABoard: TBoard);
252+ // hiddenƒf[ƒ^Žæ“¾
253+ procedure GetHiddenParameter(Rawtext: String; ABoard: TBoard);
252254 //! “ü—̓AƒVƒXƒg‚̃|ƒbƒvƒAƒbƒvƒƒjƒ…[‚̃NƒŠƒbƒNƒCƒxƒ“ƒg
253255 procedure InputAssistMenuClick(Sender: TObject);
254256 //! TMemo‚̃J[ƒ\ƒ‹ˆÊ’u‚É•¶Žš—ñ‘}“ü
@@ -832,7 +834,10 @@ begin
832834
833835 if MsgResult = IDYES then begin
834836 GetCookie(Indy.Response.RawHeaders.Text, Board);
835-
837+ if (Board.Is2ch) then begin
838+ GetHiddenParameter(ResponseText, Board);
839+ end;
840+
836841 if (Board.SPID = '') and (Board.PON = '') and (Board.Cookie = '') then
837842 raise Exception.Create('');
838843
@@ -860,6 +865,9 @@ begin
860865
861866 if MsgResult = IDYES then begin
862867 GetCookie(Indy.Response.RawHeaders.Text, Board);
868+ if (Board.Is2ch) then begin
869+ GetHiddenParameter(ResponseText, Board);
870+ end;
863871
864872 if (Board.SPID = '') and (Board.PON = '') and (Board.Cookie = '') then
865873 raise Exception.Create('');
@@ -1898,7 +1906,90 @@ begin
18981906 end;
18991907 end;
19001908 end;
1909+//! hiddenƒf[ƒ^Žæ“¾
1910+procedure TEditorForm.GetHiddenParameter(Rawtext: String; ABoard: TBoard);
1911+const
1912+ INPUT_MARK = '<input type=hidden' ; // ‘啶Žš¬•¶Žš‚΂ç‚΂ç‚È‚±‚Æ‚É’ˆÓ
1913+ VALUE_MARK = 'value=' ; // ‘啶Žš¬•¶Žš‚΂ç‚΂ç‚È‚±‚Æ‚É’ˆÓ
1914+ NAME_MARK = 'name=' ; // ‘啶Žš¬•¶Žš‚΂ç‚΂ç‚È‚±‚Æ‚É’ˆÓ
1915+ IGNORE_NAMES : array[0..6] of String =
1916+ ('subject', 'from', 'mail', 'message', 'bbs', 'time', 'key');
1917+var
1918+ tmp, line, name, value, lname : String;
1919+ pos, pose, i : Integer;
1920+begin
1921+ tmp := AnsiLowerCase(Rawtext);
1922+ pos := AnsiPos(INPUT_MARK, tmp);
1923+ while (pos > 0 ) do begin
1924+ tmp := Copy(Rawtext, pos + Length(INPUT_MARK), Length(tmp));
1925+ Delete(Rawtext, 1, pos+ Length(INPUT_MARK) - 1);
1926+ pose := AnsiPos('>', tmp);
1927+ // name=xxx value=yyy ‚ªØ‚èo‚³‚ê‚é
1928+ line := Copy(tmp, 1, pose - 1);
1929+ name := '';
1930+ value := '';
1931+ pos := AnsiPos(NAME_MARK, tmp);
1932+ if (pos > 0) then begin
1933+ name := Copy(Rawtext, pos + Length(NAME_MARK), Length(line));
1934+ //”¼Šp"‚ÅŽn‚Ü‚Á‚Ä‚¢‚é‚©
1935+ if AnsiPos('"', name) = 1 then begin
1936+ // ”¼Šp"‚Ü‚Å‚ðƒRƒs[
1937+ Delete(name, 1, 1);
1938+ pose := AnsiPos('"', name);
1939+ if (pose > 0) then begin
1940+ Delete(name, pose, Length(name));
1941+ end else begin
1942+ pose := AnsiPos(' ', name);
1943+ if (pose > 0) then begin
1944+ Delete(name, pose, Length(name));
1945+ end;
1946+ end;
1947+ end else begin
1948+ pose := AnsiPos(' ', name);
1949+ if (pose > 0) then begin
1950+ Delete(name, pose, Length(name));
1951+ end;
1952+ end;
1953+ end;
1954+ lname := AnsiLowerCase(name);
1955+ for i := 0 to Length(IGNORE_NAMES) do begin
1956+ if lname = IGNORE_NAMES[i] then begin
1957+ name := '';
1958+ break;
1959+ end;
1960+ end;
1961+ pos := AnsiPos(VALUE_MARK, tmp);
1962+ if (name <> '') and (pos > 0) then begin
1963+ value := Copy(Rawtext, pos + Length(VALUE_MARK), Length(line));
1964+ //”¼Šp"‚ÅŽn‚Ü‚Á‚Ä‚¢‚é‚©
1965+ if AnsiPos('"', value) = 1 then begin
1966+ // ”¼Šp"‚Ü‚Å‚ðƒRƒs[
1967+ Delete(value, 1, 1);
1968+ pose := AnsiPos('"', value);
1969+ if (pose > 0) then begin
1970+ Delete(value, pose, Length(value));
1971+ end else begin
1972+ pose := AnsiPos(' ', value);
1973+ if (pose > 0) then begin
1974+ Delete(value, pose, Length(value));
1975+ end;
1976+ end;
1977+ end else begin
1978+ pose := AnsiPos(' ', value);
1979+ if (pose > 0) then begin
1980+ Delete(value, pose, Length(name));
1981+ end;
1982+ end;
1983+ end;
1984+ if (name <> '') then begin
1985+ ABoard.Cookie := ABoard.Cookie + name + '=' + value + '; ';
19011986
1987+ end;
1988+ Delete(tmp, 1, Length(line));
1989+ Delete(Rawtext, 1, Length(line));
1990+ pos := AnsiPos(INPUT_MARK, tmp);
1991+ end;
1992+end;
19021993
19031994 //! ƒTƒ“ƒoXV‚̃AƒNƒVƒ‡ƒ“‚ÌUpdateƒCƒxƒ“ƒg@ŠÈ’P‚Ì‚½‚߃^ƒCƒ}[‚Æ“¯‚¶‚É‚µ‚Ä‚¨‚­
19041995 procedure TEditorForm.UpdateSambaActionUpdate(Sender: TObject);
@@ -2341,8 +2432,7 @@ begin
23412432 Result := Result + 'MDMD=' + GikoSys.Setting.BeCode + '; '
23422433 + 'DMDM=' + GikoSys.Setting.BeUserID + '; ';
23432434 end;
2344-
2345- end;
2435+ end;
23462436
23472437 Result := 'Cookie: ' + Result + 'NAME=' + NameComboBox.Text + '; MAIL=' + MailComboBox.Text;
23482438
--- a/GikoSystem.pas
+++ b/GikoSystem.pas
@@ -264,7 +264,7 @@ const
264264 ZERO_DATE: Integer = 25569;
265265 BETA_VERSION_NAME_E = 'beta';
266266 BETA_VERSION_NAME_J = 'ÊÞÀ';
267- BETA_VERSION = 58;
267+ BETA_VERSION = 59;
268268 BETA_VERSION_BUILD = ''; //!< debug”Å‚È‚Ç
269269 APP_NAME = 'gikoNavi';
270270 BE_PHP_URL = 'http://be.2ch.net/test/p.php?i=';
@@ -1891,84 +1891,76 @@ http://2ch.net/
18911891 ‚̏ꍇ stRef = 32, endRes = 50 ‚É‚È‚é
18921892 }
18931893 procedure TGikoSys.GetPopupResNumber(URL : string; var stRes, endRes : Int64);
1894+const
1895+ START_NAME : array[0..1] of String = ('st=', 'start=');
1896+ END_NAME : array[0..1] of String = ('to=', 'end=');
1897+ RES_NAME : array[0..0] of String = ('res=');
18941898 var
18951899 buf : String;
18961900 convBuf : String;
18971901 ps : Int64;
18981902 pch : PChar;
1903+ bufList : TStringList;
1904+ i, j, idx : Integer;
18991905 begin
19001906 URL := Trim(LowerCase(URL));
1901- if (AnsiPos('&st=', URL ) <> 0) and ( AnsiPos( '&to=',URL) <> 0 ) then begin
1902- stRes := 0;
1903- endRes := 0;
1904- try
1905- buf := Copy( URL, AnsiPos('&st=', URL ) + 4, AnsiPos( '&to=',URL) - AnsiPos('&st=', URL ) - 4 );
1906- if buf <> '' then
1907- stRes := StrToInt64( buf );
1908- if AnsiPos( '&nofirst=',URL) <> 0 then begin
1909- buf := Copy( URL, AnsiPos('&to=', URL ) + 4, AnsiPos( '&nofirst=',URL) - AnsiPos('&to=', URL ) - 4);
1910- end else begin
1911- buf := Copy( URL, AnsiPos('&to=', URL ) + 4, Length( URL ) - AnsiPos('&to=', URL ) - 4 + 1 );
1912- ps := 0;
1913- pch := PChar(buf);
1914- while ( ps < Length(buf) )and ( pch[ps] >= '0' ) and ( pch[ps] <= '9' ) do Inc(ps);
1915- buf := Copy( buf, 1, ps );
1916- end;
1917- try
1918- if buf <> '' then
1919- endRes := StrToInt64(buf)
1920- except
1921- endRes := 0;
1922- end;
1923- except
1924- stRes := 0;
1925- end;
1926- if (stRes <> 0) and (endRes = 0) then
1927- endRes := stRes + MAX_POPUP_RES
1928- else if (stRes = 0) and (endRes <> 0) then begin
1929- stRes := endRes - MAX_POPUP_RES;
1930- if stRes < 1 then
1931- stRes := 1;
1932- end;
1933- GikoSys.GetBrowsableThreadURL( URL );
1934- end else if( AnsiPos('&res=', URL ) <> 0 ) then begin
1935- endRes := 0;
1936- buf := Copy( URL, AnsiPos('&res=', URL ) + 5, Length( URL ) - AnsiPos('&res=', URL ) - 5 + 1 );
1937- ps := 0;
1938- pch := PChar(buf);
1939- while ( ps < Length(buf) )and ( pch[ps] >= '0' ) and ( pch[ps] <= '9' ) do Inc(ps);
1940- buf := Copy( buf, 1, ps );
1941- try
1942- if buf <> '' then
1943- stRes := StrToInt(buf)
1944- else begin
1945- stRes := 0;
1946- end;
1947- except
1948- stRes := 0;
1949- end;
1950- end else if (AnsiPos('&start=', URL ) <> 0) and ( AnsiPos( '&end=',URL) <> 0 ) then begin
1951- try
1952- stRes := StrToInt64( Copy( URL, AnsiPos('&start=', URL ) + 7, AnsiPos( '&end=',URL) - AnsiPos('&start=', URL ) - 7 ) );
1953- if AnsiPos( '&nofirst=',URL) <> 0 then begin
1954- buf := Copy( URL, AnsiPos('&end=', URL ) + 5, AnsiPos( '&nofirst=',URL) - AnsiPos('&end=', URL ) - 5);
1955- end else begin
1956- buf := Copy( URL, AnsiPos('&end=', URL ) + 5, Length( URL ) - AnsiPos('&to=', URL ) - 5 + 1 );
1957- ps := 0;
1958- pch := PChar(buf);
1959- while ( ps < Length(buf) )and ( pch[ps] >= '0' ) and ( pch[ps] <= '9' ) do Inc(ps);
1960- buf := Copy( buf, 1, ps );
1961- end;
1962- try
1963- if buf <> '' then
1964- endRes := StrToInt64(buf);
1965- except
1966- endRes := 0;
1967- end;
1968- except
1969- stRes := 0;
1970- end;
1971- end else if ( AnsiPos('.html',URL) <> Length(URL) -4 ) and ( AnsiPos('.htm',URL) <> Length(URL) -3 ) then begin
1907+ idx := AnsiPos('?', URL);
1908+ if (idx <> 0) then begin
1909+ stRes := 0;
1910+ endRes := 0;
1911+ bufList := TStringList.Create();
1912+ try
1913+ bufList.Delimiter := '&';
1914+ bufList.DelimitedText := Copy(URL, idx + 1, Length(URL));
1915+ for i := 0 to bufList.Count - 1 do begin
1916+ convBuf := '';
1917+ // ŠJŽnƒŒƒX”Ô‚ÌŒŸõ
1918+ for j := 0 to Length(START_NAME) - 1 do begin
1919+ idx := AnsiPos(START_NAME[j], bufList[i]);
1920+ if (idx <> 0) then begin
1921+ convBuf := Copy(bufList[i], idx + Length(START_NAME[j]), Length(bufList[i]));
1922+ stRes := StrToInt64Def( convBuf, 0 );
1923+ break;
1924+ end;
1925+ end;
1926+ // I—¹ƒŒƒX”Ô‚ÌŒŸõ
1927+ if (convBuf = '') then begin
1928+ for j := 0 to Length(END_NAME) - 1 do begin
1929+ idx := AnsiPos(END_NAME[j], bufList[i]);
1930+ if (idx <> 0) then begin
1931+ convBuf := Copy(bufList[i], idx + Length(END_NAME[j]), Length(bufList[i]));
1932+ endRes := StrToInt64Def( convBuf, 0 );
1933+ break;
1934+ end;
1935+ end;
1936+ end;
1937+ // ƒŒƒX”Ô‚ÌŒŸõ
1938+ if ((stRes = 0) and (endRes = 0) and (convBuf = '')) then begin
1939+ for j := 0 to Length(RES_NAME) - 1 do begin
1940+ idx := AnsiPos(RES_NAME[j], bufList[i]);
1941+ if (idx <> 0) then begin
1942+ convBuf := Copy(bufList[i], idx + Length(RES_NAME[j]), Length(bufList[i]));
1943+ stRes := StrToInt64Def( convBuf, 0 );
1944+ endRes := stRes;
1945+ break;
1946+ end;
1947+ end;
1948+ end;
1949+ end;
1950+
1951+ if (stRes <> 0) and (endRes = 0) then begin
1952+ endRes := stRes + MAX_POPUP_RES;
1953+ end else if (stRes = 0) and (endRes <> 0) then begin
1954+ stRes := endRes - MAX_POPUP_RES;
1955+ if stRes < 1 then begin
1956+ stRes := 1;
1957+ end;
1958+ end;
1959+ finally
1960+ bufList.clear;
1961+ bufList.free;
1962+ end;
1963+ end else if ( AnsiPos('.html',URL) <> Length(URL) -4 ) and ( AnsiPos('.htm',URL) <> Length(URL) -3 ) then begin
19721964 buf := Copy(URL, LastDelimiter('/',URL)+1,Length(URL)-LastDelimiter('/',URL)+1);
19731965 if Length(buf) > 0 then begin
19741966 if AnsiPos('-', buf) = 1 then begin
@@ -1977,15 +1969,10 @@ begin
19771969 ps := 0;
19781970 pch := PChar(buf);
19791971 while ( ps < Length(buf) )and ( pch[ps] >= '0' ) and ( pch[ps] <= '9' ) do Inc(ps);
1980- try
1981- convBuf := Copy( buf, 1, ps );
1982- if convBuf <> '' then
1983- endRes := StrToInt64(convBuf)
1984- else
1985- endRes := 0;
1986- except
1987- endRes := 0;
1988- end;
1972+ convBuf := Copy( buf, 1, ps );
1973+ if convBuf <> '' then begin
1974+ endRes := StrToInt64Def(convBuf, 0);
1975+ end;
19891976 if endRes <> 0 then begin
19901977 stRes := endRes - MAX_POPUP_RES;
19911978 if stRes < 1 then
@@ -2003,15 +1990,10 @@ begin
20031990 ps := 0;
20041991 pch := PChar(buf);
20051992 while ( ps < Length(buf) )and ( pch[ps] >= '0' ) and ( pch[ps] <= '9' ) do Inc(ps);
2006- try
2007- convBuf := Copy( buf, 1, ps );
2008- if convBuf <> '' then
2009- endRes := StrToInt64(convBuf)
2010- else
2011- endRes := 0;
2012- except
2013- endRes := 0;
2014- end;
1993+ convBuf := Copy( buf, 1, ps );
1994+ if convBuf <> '' then begin
1995+ endRes := StrToInt64Def(convBuf, 0);
1996+ end;
20151997 end else begin
20161998 stRes := 0;
20171999 end;
@@ -2021,9 +2003,6 @@ begin
20212003 end;
20222004 end;
20232005 end;
2024- end else begin
2025- //stRes := 0;
2026- //endRes := 0;
20272006 end;
20282007 end;
20292008
--- a/HTMLCreate.pas
+++ b/HTMLCreate.pas
@@ -1481,30 +1481,31 @@ end;
14811481 class function THTMLCreate.DeleteLink(const s: string): string;
14821482 var
14831483 s1: string;
1484- s2: string;
1484+ mark: string;
14851485 idx: Integer;
1486- i: Integer;
14871486 begin
1488- i := 0;
1489- Result := '';
1490- while True do begin
1491- s1 := GikoSys.GetTokenIndex(s, '<a href="', i);
1492- s2 := GikoSys.GetTokenIndex(s, '<a href="', i + 1);
1493-
1494- idx := Pos('">', s1);
1495- if idx <> 0 then
1496- Delete(s1, 1, idx + 1);
1497- idx := Pos('">', s2);
1498- if idx <> 0 then
1499- Delete(s2, 1, idx + 1);
1500-
1501- Result := Result + s1 + s2;
1502-
1503- if s2 = '' then
1504- Break;
1487+ mark := '<a href="';
1488+ Result := '';
1489+ s1 := s;
1490+ idx := AnsiPos(mark, s1);
1491+ while idx <> 0 do begin
1492+ Result := Copy(s1, 1, idx - 1);
1493+ Delete(s1, 1, idx);
1494+ // ƒ^ƒO‚̃Gƒ“ƒh‚ð’T‚·
1495+ idx := AnsiPos('">', s1);
1496+ if idx <> 0 then begin
1497+ Delete(s1, 1, idx + 1);
1498+ end;
1499+ // </a> ‚Ü‚Å
1500+ idx := AnsiPos('</a>', s1);
1501+ if idx <> 0 then begin
1502+ Result := Result + Copy(s1, 1, idx - 1);
1503+ Delete(s1, 1, idx + 4);
1504+ end;
1505+ idx := AnsiPos(mark, s1);
1506+ end;
15051507
1506- inc(i, 2);
1507- end;
1508+ Result := Result + s1;
15081509 end;
15091510 {
15101511 \brief HTML‰»‚Ì‚½‚ß‚Ì’uŠ·
--- a/Setting.pas
+++ b/Setting.pas
@@ -859,7 +859,7 @@ const
859859 SPAMFILTER_FILE_NAME = 'SpamFilter.ini';
860860 LANGUAGE_FILE_NAME = 'language.ini';
861861 INPUTASSIST_FILE_NAME = 'InputAssist.ini';
862- FIXED_COOKIE = 'hana=mogera';
862+ FIXED_COOKIE = '';
863863 REPLACE_FILE_NAME = 'replace.ini';
864864 EXT_PREVIEW_FILE_NAME = 'extpreview.ini';
865865
Binary files a/gikoNavi.res and b/gikoNavi.res differ
--- a/readme/gikoSetup.iss
+++ b/readme/gikoSetup.iss
@@ -13,8 +13,8 @@ SourceDir=G:\Release
1313 OutputDir=G:\InnoSetup\Output
1414 SetupIconFile="G:\gikoNaviSFX_102\MainIcon.ico"
1515 ; ƒMƒRƒiƒr‚̃o[ƒWƒ‡ƒ“‚É‚ ‚킹‚Ä‚­‚¾‚³‚¢
16-VersionInfoVersion=1.57.1.744
17-OutputBaseFilename=gikoNavi_b57_setup
16+VersionInfoVersion=1.58.1.764
17+OutputBaseFilename=gikoNavi_b58_setup
1818
1919
2020 [Tasks]
--- a/readme/readme.txt
+++ b/readme/readme.txt
@@ -1,4 +1,4 @@
1-¡ƒMƒRƒiƒr Version1.00 ÊÞÀ58 Readme.txt
1+¡ƒMƒRƒiƒr Version1.00 ÊÞÀ59 Readme.txt
22
33
44 ------------------------------
@@ -108,7 +108,10 @@ LICENSE
108108 ------------------------------
109109 —š—ð
110110 ------------------------------
111-2008/09/20
111+2008/XX/XX
112+ Version ÊÞÀ59
113+
114+2008/09/16
112115 Version ÊÞÀ58
113116 ƒvƒŒƒrƒ…[‚ÌURL‚©‚ç“o˜^‚µ‚Ä‚ ‚éŠO•”ƒAƒvƒŠ‚ð‹N“®‚·‚é‹@”\‚ð’ljÁ
114117 ƒŒƒX‘—MƒGƒfƒBƒ^‚ŁA˜A‘±‚µ‚Ä“Še‚Å‚«‚é‚悤‚É‚·‚é‹@”\‚ð’ljÁ
--- a/res/skin/Skin011/NewRes.html
+++ b/res/skin/Skin011/NewRes.html
@@ -2,6 +2,6 @@
22 <span class="top"><a href="menu:<PLAINNUMBER/>" name="<PLAINNUMBER/>"><img src="<SKINPATH/>img\n_l.gif" class="left"></a>
33 <span class="name">No.<PLAINNUMBER/>F<NAME/></span><img src="<SKINPATH/>img\r.gif" class="right"></span><span
44 class="main">
5-<span class="date"><MAIL/> [<DATE/>]</span>
5+<span class="date"><MAIL/> <DATE/></span>
66 <span class="message"><MESSAGE/></span></span>
77 </div>
--- a/res/skin/Skin011/Res.html
+++ b/res/skin/Skin011/Res.html
@@ -1,6 +1,6 @@
11 <div><span class="top"><a href="menu:<PLAINNUMBER/>" name="<PLAINNUMBER/>"><img src="<SKINPATH/>img\o_l.gif" class="left"></a>
22 <span class="name">No.<PLAINNUMBER/>F<NAME/>@</span><img src="<SKINPATH/>img\r.gif" class="right"></span><span
33 class="main">
4-<span class="date"><MAIL/> [<DATE/>]</span>
4+<span class="date"><MAIL/> <DATE/></span>
55 <span class="message"><MESSAGE/></span></span>
66 </div>