OSDN Git Service
(root)
/
gikonavigoeson
/
gikonavi.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
・スレタイの特定ワードを非表示にする機能に「©bbspink.com」も追加
[gikonavigoeson/gikonavi.git]
/
MojuUtils.pas
diff --git
a/MojuUtils.pas
b/MojuUtils.pas
index
4291e20
..
4c87fb0
100644
(file)
--- a/
MojuUtils.pas
+++ b/
MojuUtils.pas
@@
-366,23
+366,26
@@
begin
p := pos - pss;
SetString(Result, pss, p);
Delete(s, 1, p + Length(delimiter));
p := pos - pss;
SetString(Result, pss, p);
Delete(s, 1, p + Length(delimiter));
-
- if (StrByteType(PChar(Result), Length(Result)-1) = mbLeadByte) then begin
- SetLength(Result, Length(Result) - 1);
- end;
+ if (Length(Result) > 0) then begin
+ if (StrByteType(PChar(Result), Length(Result)-1) = mbLeadByte) then begin
+ SetLength(Result, Length(Result) - 1);
+ end;
+ end;
end else begin
Result := s;
s := '';
end;
end;
end else begin
Result := s;
s := '';
end;
end;
-//!
\96
³
\8a
Q
\89
»(& -> & " -> &
a
uot;
\82
É
\95
Ï
\8a
·
\82
·
\82
é)
+//!
\96
³
\8a
Q
\89
»(& -> & " -> &
q
uot;
\82
É
\95
Ï
\8a
·
\82
·
\82
é)
function Sanitize(const s: String): String;
begin
function Sanitize(const s: String): String;
begin
- Result := CustomStringReplace(s, '&', '&');
+ //
\97
]
\95
ª
\82
É
\83
T
\83
j
\83
^
\83
C
\83
Y
\82
³
\82
ê
\82
È
\82
¢
\82
æ
\82
¤
\82
É
\82
¢
\82
Á
\82
½
\82
ñ
\8c
³
\82
É
\96
ß
\82
·
+ Result := UnSanitize(s);
+ Result := CustomStringReplace(Result, '&', '&');
Result := CustomStringReplace(Result, '"', '"');
end;
Result := CustomStringReplace(Result, '"', '"');
end;
-//!
\96
³
\8a
Q
\89
»
\89
ð
\8f
\9c
(& -> & &
a
uot; -> "
\82
É
\95
Ï
\8a
·
\82
·
\82
é)
+//!
\96
³
\8a
Q
\89
»
\89
ð
\8f
\9c
(& -> & &
q
uot; -> "
\82
É
\95
Ï
\8a
·
\82
·
\82
é)
function UnSanitize(const s: String): String;
begin
Result := CustomStringReplace(s, '"', '"');
function UnSanitize(const s: String): String;
begin
Result := CustomStringReplace(s, '"', '"');