aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZeus Panchenko <zeus@camb.us>2006-07-13 09:44:44 +0000
committerZeus Panchenko <zeus@camb.us>2006-07-13 09:44:44 +0000
commit70659696bffb3fea8ee6546928d0846e02d167a2 (patch)
treee6743507d991b09df5bc118f4b98358102727d08
parentad2c998f6058e58cfc703c5c0e32eaeaedf574fb (diff)
downloadrenrot-70659696bffb3fea8ee6546928d0846e02d167a2.tar.gz
renrot-70659696bffb3fea8ee6546928d0846e02d167a2.tar.bz2
Bugfix, tag Keywords was accumulated in the loop rather than written once.
git-svn-id: file:///svnroot/renrot/trunk@221 fe2816f4-e837-0410-b10a-f608c9d244a1
-rw-r--r--ChangeLog4
-rwxr-xr-xrenrot11
2 files changed, 9 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index 07bcf1f..81bb72a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,7 @@
$Log$
+Revision 1.143 2006/07/13 09:44:44 zeus
+Bugfix, tag Keywords was accumulated in the loop rather than written once.
+
Revision 1.142 2006/07/08 05:04:24 andy
Optimize keywordizer code. Should be checked.
@@ -568,3 +571,4 @@ Id keyword is added to renrot file.
Revision 1.1 2005/10/17 13:39:38 zeus
ChangeLog file is added. Its the very begining.
+
diff --git a/renrot b/renrot
index 401977d..63e364a 100755
--- a/renrot
+++ b/renrot
@@ -677,6 +677,10 @@ sub renRotProcess {
procmsg ("RENAMING / ROTATING\n===================\n");
+ if (scalar(@keywordArr) > 0) {
+ $exifTool->SetNewValue(Keywords => \@keywordArr);
+ }
+
foreach my $file (@files) {
procmsg ("Processing file: $file ...\n");
@@ -690,7 +694,7 @@ sub renRotProcess {
$newFileName = renameFile($exifTool, $info, $file, $fileCounter);
# Writting tags.
- tagWriter($exifTool, $newFileName, @keywordArr) if ($noRename == 0);
+ tagWriter($exifTool, $newFileName) if ($noRename == 0);
# seting mtime for the file if been asked for
mtimeSet($exifTool, $info, $newFileName);
@@ -855,17 +859,12 @@ sub mtimeSet {
sub tagWriter {
my $exifToolObj = shift;
my $file = shift;
- my @keywordArr = @_;
dbgmsg (2, "tagWriter(): Writting tags to file...\n");
foreach my $key (sort (keys %tags)) {
$exifToolObj->SetNewValue($key, $tags{$key}{value}, Group => $tags{$key}{group});
}
- if (scalar(@keywordArr) > 0) {
- $exifTool->SetNewValue(Keywords => \@keywordArr);
- }
-
# writing the changes to the EXIFs
if ($dryRun == 0) { exifWriter($exifToolObj, $file); }
else { procmsg ("Writting user defined EXIF tags.\n"); }

Return to:

Send suggestions and report system problems to the System administrator.