Permalink
Browse files

fix remaining dialyzer warnings

  • Loading branch information...
1 parent 0c9dff3 commit 5ff69ad2870f749deac12a0a18a827725bd848ad @argv0 argv0 committed Mar 18, 2013
Showing with 20 additions and 20 deletions.
  1. +6 −4 dialyzer.ignore-warnings
  2. +1 −0 src/riak_cs_riakc_pool_worker.erl
  3. +4 −9 src/riak_cs_wm_ping.erl
  4. +9 −7 xref.ignore-warnings
View
@@ -82,6 +82,8 @@
riak_object:key/1
riak_object:new/3
riak_object:update_metadata/2
+ riak_repl_pb_api:get/5
+ riak_repl_pb_api:get_clusterid/2
calendar:day/0
calendar:hour/0
calendar:month/0
@@ -165,7 +167,7 @@ riak_cs_gc_d.erl:381: Function gc_index_query/2 will never be called
riak_cs_storage_d.erl:332: Function fetch_user_list/1 will never be called
riak_cs_wm_ping.erl:46: The pattern 'undefined' can never match the type pid()
############## All the others..........
-riak_cs_blockall_auth.erl:9: Callback info about the riak_cs_auth behaviour is not available
-riak_cs_passthru_auth.erl:9: Callback info about the riak_cs_auth behaviour is not available
-riak_cs_s3_auth.erl:9: Callback info about the riak_cs_auth behaviour is not available
-riak_cs_s3_policy.erl:12: Callback info about the riak_cs_policy behaviour is not available
+riak_cs_blockall_auth.erl:23: Callback info about the riak_cs_auth behaviour is not available
+riak_cs_passthru_auth.erl:23: Callback info about the riak_cs_auth behaviour is not available
+riak_cs_s3_auth.erl:23: Callback info about the riak_cs_auth behaviour is not available
+riak_cs_s3_policy.erl:26: Callback info about the riak_cs_policy behaviour is not available
@@ -26,6 +26,7 @@
start_link/1,
stop/1]).
+-spec riak_host_port() -> {string(), pos_integer()}.
riak_host_port() ->
case application:get_env(riak_cs, riak_ip) of
{ok, Host} ->
View
@@ -56,16 +56,11 @@ service_available(RD, Ctx) ->
Pid ->
UpdCtx = Ctx#ping_context{riakc_pid=Pid}
end,
- case Pid of
- undefined ->
- Available = false;
+ case (catch riakc_pb_socket:ping(Pid, ping_timeout())) of
+ pong ->
+ Available = true;
_ ->
- case (catch riakc_pb_socket:ping(Pid, ping_timeout())) of
- pong ->
- Available = true;
- _ ->
- Available = false
- end
+ Available = false
end,
{Available, RD, UpdCtx}.
View
@@ -1,17 +1,19 @@
######## mapreduce functions calling into a riak_kv environment / code path
src/riak_cs_storage.erl:67: Warning object_size_map/3 calls undefined function riak_object:get_values/1
-src/riak_cs_utils.erl:476: Warning map_keys_and_manifests/3 calls undefined function riak_object:get_values/1
-src/riak_cs_utils.erl:476: Warning map_keys_and_manifests/3 calls undefined function riak_object:key/1
+src/riak_cs_utils.erl:493: Warning map_keys_and_manifests/3 calls undefined function riak_object:get_values/1
+src/riak_cs_utils.erl:493: Warning map_keys_and_manifests/3 calls undefined function riak_object:key/1
######## kv backends calling into kv/core code
src/riak_cs_kv_multi_backend.erl:369: Warning get_backend_bucketprops/2 calls undefined function riak_core_bucket:get_bucket/1
src/riak_cs_kv_multi_backend.erl:142: Warning start/2 calls undefined function app_helper:get_prop_or_env/3
src/riak_cs_kv_multi_backend.erl:142: Warning start/2 calls undefined function app_helper:get_prop_or_env/4
src/riak_kv_fs2_backend.erl:89: Warning start/2 calls undefined function app_helper:get_prop_or_env/3
src/riak_kv_fs2_backend.erl:89: Warning start/2 calls undefined function riak:stop/1
+src/riak_cs_block_server.erl:172: Warning handle_cast/2 calls undefined function riak_repl_pb_api:get/5
+src/riak_cs_storage.erl:81: Warning object_size_map/3 calls undefined function riak_object:get_values/1
+src/riak_cs_utils.erl:1467: Warning get_cluster_id/1 calls undefined function riak_repl_pb_api:get_clusterid/2
######## testing code
-src/riak_cs_manifest_fsm.erl:141: Warning init/1 calls undefined function riakc_pb_socket_fake:start_link/0
-src/riak_cs_manifest_fsm.erl:141: Warning init/1 calls undefined function riakc_pb_socket_fake:start_link/0
-src/riak_cs_get_fsm.erl:101: Warning init/1 calls undefined function riak_cs_dummy_reader:get_manifest/1
-src/riak_cs_get_fsm.erl:101: Warning init/1 calls undefined function riak_cs_dummy_reader:start_link/1
+src/riak_cs_manifest_fsm.erl:155: Warning init/1 calls undefined function riakc_pb_socket_fake:start_link/0
+src/riak_cs_get_fsm.erl:115: Warning init/1 calls undefined function riak_cs_dummy_reader:get_manifest/1
+src/riak_cs_get_fsm.erl:115: Warning init/1 calls undefined function riak_cs_dummy_reader:start_link/1
######## optional vm features
-src/riak_cs_sup.erl:45: Warning init/1 calls undefined function dtrace:init/0
+src/riak_cs_sup.erl:59: Warning init/1 calls undefined function dtrace:init/0

0 comments on commit 5ff69ad

Please sign in to comment.