Last Comment Bug 722305 - Remove contentAreaClick's redundant return value
: Remove contentAreaClick's redundant return value
Status: RESOLVED FIXED
[good first bug][mentor=dao][lang=js]
:
Product: Firefox
Classification: Client Software
Component: General (show other bugs)
: Trunk
: All All
: -- trivial (vote)
: Firefox 13
Assigned To: Veeraya Pupatwibul
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-01-30 06:42 PST by Dão Gottwald [:dao]
Modified: 2012-02-10 19:45 PST (History)
5 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
first patch to Bug 722305 (6.86 KB, patch)
2012-02-08 11:03 PST, Veeraya Pupatwibul
dao+bmo: review+
Details | Diff | Splinter Review
2nd patch (6.66 KB, patch)
2012-02-09 06:46 PST, Veeraya Pupatwibul
dao+bmo: review+
Details | Diff | Splinter Review

Description Dão Gottwald [:dao] 2012-01-30 06:42:05 PST
contentAreaClick always returns true. This isn't useful. It should stop returning something and our three callers should stop reading the return value:

http://mxr.mozilla.org/mozilla-central/search?string=contentAreaClick%28e
Comment 1 Veeraya Pupatwibul 2012-02-01 09:17:44 PST
Hi, I'd like to work on this bug. It's my first attempt at fixing bugs. Could someone please mentor me? I already have the source code from https://developer.mozilla.org/En/Simple_Firefox_build. What's next? Make patches and attach them here? Thank you!
Comment 2 Dão Gottwald [:dao] 2012-02-01 10:49:50 PST
(In reply to Veeraya Pupatwibul from comment #1)
> What's next? Make patches and attach them here?

Yes. :) Have you seen <https://developer.mozilla.org/en/Creating_a_patch>?
Comment 3 [retired] 2012-02-06 14:37:31 PST
(In reply to Veeraya Pupatwibul from comment #1)
> Hi, I'd like to work on this bug. It's my first attempt at fixing bugs.
> Could someone please mentor me? I already have the source code from
> https://developer.mozilla.org/En/Simple_Firefox_build. What's next? Make
> patches and attach them here? Thank you!

I'll assign it to you. If, for some reason, you don't want to work on this anymore, I can take it ;)
Comment 4 Veeraya Pupatwibul 2012-02-08 11:03:53 PST
Created attachment 595455 [details] [diff] [review]
first patch to Bug 722305

First patch. Function now doesn't return any value and callers don't read return value anymore. Hope I did it correctly:)
Comment 5 Dão Gottwald [:dao] 2012-02-09 01:24:45 PST
Comment on attachment 595455 [details] [diff] [review]
first patch to Bug 722305

>   // Mark the page as a user followed link.  This is done so that history can
>   // distinguish automatic embed visits from user activated ones.  For example
>   // pages loaded in frames are embed visits and lost with the session, while
>   // visits across frames should be preserved.
>   try {
>     PlacesUIUtils.markPageAsFollowedLink(href);
>   } catch (ex) { /* Skip invalid URIs. */ }
> 
>-  return true;
>+  return;
> }

nit: remove this final return, as it's a no-op now
Comment 6 Veeraya Pupatwibul 2012-02-09 06:46:00 PST
Created attachment 595718 [details] [diff] [review]
2nd patch

remove the final return
Comment 7 Dão Gottwald [:dao] 2012-02-09 06:59:58 PST
Comment on attachment 595718 [details] [diff] [review]
2nd patch

perfect, thanks!
Comment 8 Mozilla RelEng Bot 2012-02-09 08:23:25 PST
Autoland Patchset:
	Patches: 595718
	Branch: mozilla-central => try
	Destination: http://hg.mozilla.org/try/rev/a404e743e1db
Try run started, revision a404e743e1db. To cancel or monitor the job, see: https://tbpl.mozilla.org/?tree=Try&rev=a404e743e1db
Comment 9 Mozilla RelEng Bot 2012-02-09 16:30:20 PST
Try run for a404e743e1db is complete.
Detailed breakdown of the results available here:
    https://tbpl.mozilla.org/?tree=Try&rev=a404e743e1db
Results (out of 211 total builds):
    success: 179
    warnings: 18
    failure: 14
Builds (or logs if builds failed) available at:
http://ftp.mozilla.org/pub/mozilla.org/firefox/try-builds/autolanduser@mozilla.com-a404e743e1db
Comment 11 Ed Morley [:emorley] 2012-02-10 19:45:24 PST
https://hg.mozilla.org/mozilla-central/rev/f8e9d1339b7b

Congratulations on your first patch in the tree! Hope to see you on IRC (http://irc.mozilla.org/) in #developers soon :-)

Note You need to log in before you can comment on or make changes to this bug.